Object.fromEntries(Object.entries(o).map(([,n])=>{const{top:s,left:a,height:l,width:i}=n[e],r={...n[e],height:l,width:i,left:a,top:s-t};return[n.elementId,r]})),Zp=({elementsPositions:t,topOffset:e=0,elementPositionKey:o})=>Object.fromEntries(Object.entries(t).map(([n,s])=>{const{top:a,left:l,width:i,height:r}=Os(s);return[n,{[o]:{...s,top:a+e,left:l,width:i,height:r}}]})),oi=t=>[Uo,un].includes(t),Bc=({defaultLocalePages:t})=>Object.values(t||{}).some(e=>(e==null?void 0:e.type)===Uo),Y7=()=>Do(pC)==="1",en={AI_WRITER:"aiWriter",AI_WRITER_DRAWER:"aiWriterDrawer",AI_TOOLS:"aiTools",SITE:"site",SEO:"seo",USER:"user",DOMAIN:"domain",ECOMMERCE_ADMIN:"ecommerceAdmin",ECOMMERCE:"ecommerce",CLIPBOARD:"clipboard",GAMIFICATION:"gamification",NPS:"nps",INTERCOM:"intercom",BLOG:"blog",GUI:"gui",AI_BUILDER_PREVIEW:"aiBuilderPreview",RESOURCES:"resources",GOOGLE_AUTH:"googleAuth",REFERRALS:"referrals",SAVING:"saving"},Qp={ACTIVE:"active",PENDING:"pending_setup",UPDATING:"updating",FAILED:"failed",SUSPENDED:"suspended",SUSPENDING:"suspending",ACTIVATING:"activating",COMPLETED:"completed",CREATED:"created",UNSUSPENDING:"unsuspending",DELETED:"deleted",DELETING:"deleting",DESTROYED:"destroyed",CANCELED:"canceled",EXPIRED:"expired",LOADING:"loading"},ul={VIRTUAL_MACHINE:"virtual_machine",EMAIL:"email",GOOGLE_WORKSPACE:"google_workspace",TITAN_MAIL:"titan_mail",DOMAIN:"domain",DOMAIN_TRANSFER:"domain_transfer",FREE_DOMAIN:"free_domain",FREE_DOMAIN_TRANSFER:"free_domain_transfer",CPANEL_RESELLER_HOSTING:"cpanel_reseller_hosting",DOMAIN_PRIVACY_PROTECTION:"domain_privacy_protection",HOSTING:"hosting",CPANEL_HOSTING:"cpanel_hosting",PRIORITY_SUPPORT:"priority_support",SSL:"ssl",CLOUDFLARE:"cloudflare",RANKING_COACH:"ranking_coach",WEBSITE_BUILDER:"website_builder",DAILY_BACKUP:"daily_backup"},E3=t=>{if(!t||!t.url)return{serviceName:void 0,backendPathname:void 0};let e,o;try{const n=new URL(t.url);e=n.origin,o=n.pathname}catch{e=t.baseURL,o=t.url}return{serviceName:e,backendPathname:o}},x3=t=>{var o,n;if(!t)return{message:void 0,status:void 0,code:void 0};const{data:e}=t;return{status:t.status,message:(e==null?void 0:e.message)||((o=e==null?void 0:e.error)==null?void 0:o.message),code:(e==null?void 0:e.code)||((n=e==null?void 0:e.error)==null?void 0:n.code)}},K7="Bearer ",Ac=()=>localStorage.getItem(c4),s2=()=>`${K7}${Ac()}`,Xp=t=>localStorage.setItem(c4,t),Z7=()=>{const t=Ac();if(!t)return{};const e=t.split(".")[1];if(!e)return{};const o=e.replace(/-/g,"+").replace(/_/g,"/"),n=decodeURIComponent([...window.atob(o)].map(s=>`%${`00${s.charCodeAt(0).toString(16)}`.slice(-2)}`).join(""));return JSON.parse(n)},Q7=[MC,HC,u4];let Jb=!1;const X7=t=>{var e,o;return((o=(e=t==null?void 0:t.exception)==null?void 0:e.values)==null?void 0:o.map(({value:n})=>n||""))||[]},J7=t=>X7(t).some(o=>HA.includes(o)),t9=()=>{try{Q7.forEach(t=>{const e=Do(t);e&&Yo(t,e)})}catch(t){console.error(t)}},T3=()=>{var t;try{const e=(t=Z7().profile_details)==null?void 0:t.created_at;if(!e)return;const o=new Date(e||"").getTime(),a=(Date.now()-o)/1e3/60/60<24;Yo("isFirst24HourUser",a)}catch(e){console.error(e)}},e9=["Failed to fetch dynamically imported module","Unable to preload CSS"],o9=t=>{wx({app:t,release:"prod-2060",dsn:"https://cc0ee5b1e05d417c8a46c4da579e159a@o215831.ingest.sentry.io/1879448",environment:"PROD",integrations:[kx(),Ix(),Sx()],tracesSampleRate:.02,replaysSessionSampleRate:0,replaysOnErrorSampleRate:.024,ignoreErrors:["Navigation cancelled from","ResizeObserver loop limit exceeded","ResizeObserver loop completed with undelivered notifications","Network Error"],beforeSend(e,o){var s;return J7(e)||((s=o.originalException)==null?void 0:s.name)==="AxiosError"||e9.some(a=>{var l,i;return(i=(l=o.originalException)==null?void 0:l.message)==null?void 0:i.includes(a)})||Jb?null:e}}),t9(),T3()},Jm=t=>{if(typeof t=="string"){jt(new Error(t));return}jt(t)},C3=t=>{var e;try{const{response:o,config:n}=t,{code:s,message:a}=(o==null?void 0:o.data)||{},l=(e=n==null?void 0:n.headers)==null?void 0:e[_r];Se({message:JSON.stringify({code:s,message:a,correlationId:l,errorMessage:t.message}),category:"xhr-error",level:"info"})}catch(o){jt(new Error("addAxiosErrorBreadcrumb error",{cause:o}))}},n9=()=>{Yo("serviceName",""),Yo("backendPathname",""),Yo("errorResponseMessage",""),Yo("axiosErrorMessage",""),Yo("axiosErrorCode",""),Yo("responseStatus",""),Yo("responseCode",""),Yo(_r,"")},tf=t=>{Jb=!0,setTimeout(()=>{Jb=!1},t)},P3=t=>{var e,o,n,s;try{const{response:a,config:l}=t,{code:i,message:r,status:u}=x3(a);if(!Ac()&&u===401||r==="jwt malformed"||fC.includes(t.code||"")){tf(1e3);return}if(u&&((e=l==null?void 0:l.whitelistedStatusCodes)==null?void 0:e.includes(u))||i&&((o=l==null?void 0:l.whitelistedErrorCodes)==null?void 0:o.includes(i))||((n=l==null?void 0:l.getIsResponseWhitelisted)==null?void 0:n.call(l,t)))return;if(!(l!=null&&l.url)){Jm("No request url provided");return}const{serviceName:I,backendPathname:E}=E3(l);Yo("serviceName",I),Yo("backendPathname",E),Yo("errorResponseMessage",r),Yo("axiosErrorMessage",t.message),Yo("axiosErrorCode",t.code),Yo("responseStatus",u),Yo("responseCode",i),Yo(_r,(s=l==null?void 0:l.headers)==null?void 0:s[_r]),Jm(`${I} ${E} request error`)}catch(a){Jm(new Error("logAxiosError error",{cause:a}))}tf(1e3),n9()},Ug=Vd.create({timeout:15e4,headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":"application/json"}}});Ug.interceptors.request.use(async t=>{if(t.headers.Authorization)return t;const o=Gs(),n=o.getBearerToken();return n?(t.headers.Authorization=n,t):(o.forceLogout(),t)});Ug.interceptors.request.use(t=>(t.headers&&(t.headers[_r]=Fd(36)),t));Ug.interceptors.response.use(t=>t.data,t=>(C3(t),P3(t),Promise.reject(t)));const i9=Ug,B3="https://auth.hostinger.com/api/external/v1/auth",s9=()=>i9.post(`${B3}/refresh`,{},{whitelistedStatusCodes:[401]}),th=t=>Ut.post(`${B3}/generate-token`,{target_application:t}),A3={id_ID:"id",de_DE:"de",en_GB:"en",es_AR:"es",es_CO:"es",es_MX:"es",es_ES:"es",fr_FR:"fr",it_IT:"it",lt_LT:"lt",nl_NL:"nl",pt_PT:"pt",pt_BR:"br",ru_RU:"ru",tr_TR:"tr",uk_UA:"ua",zh_CN:"zh",hi_IN:"hi",ar_AR:"sa",he_IL:"he",pl_PL:"pl",vi_VN:"vi",th_TH:"th",ro_RO:"ro",ja_JP:"ja"},ef=t=>A3[t];function oy(){return ef(K0())||Y0()||GA()}function D3(t){Mi(p4,t,365,{cdomain:".hostinger.com"})}const eh={HPANEL:"hpanel",ECOMMERCE:"website_builder_ecommerce_admin",LOGO_MAKER:"logo_maker"},dn={redirectToHpanel:async({path:t="",params:e={},target:o="_self"}={})=>{const n=Gs(),s={path:t,params:{...e}};try{n.setIsAuthRedirecting(!0);const{data:a}=await th(eh.HPANEL);s.params.jwt=a.data.token,window.open(df(s),o)}catch{window.open(df(s),o)}n.setIsAuthRedirecting(!1)},redirectToEcommerce:async({path:t="",params:e={},siteId:o=""}={})=>{const n=Gs(),s={path:t,siteId:o,params:{...e}};try{n.setIsAuthRedirecting(!0);const{data:a}=await th(eh.ECOMMERCE);s.params.jwt=a.data.token,window.open(sc(s),"_self")}catch{window.open(sc(s),"_self")}},redirectToLogoMaker:async({ref:t}={ref:""})=>{const e=Gs(),o=new URL("","https://logo.hostinger.com");o.searchParams.append("ref",t);try{e.setIsAuthRedirecting(!0);const{data:n}=await th(eh.LOGO_MAKER);o.searchParams.append("jwt",n.data.token),window.open(o,"_blank")}catch{window.open(o,"_blank")}e.setIsAuthRedirecting(!1)}},Dc="https://builder-backend.hostinger.com/v3/sites",a9=(t,e,o,n)=>{const s={siteId:t,data:e,clientTimestamp:o,flags:n};return Ut.post(`${Dc}/site`,s,{whitelistedStatusCodes:[409,403]})},a2=async t=>{const e=`${Dc}/${t}`,{data:o}=await Ut.get(e,{headers:{"Cache-Control":"no-cache",Pragma:"no-cache",Expires:"0"},whitelistedStatusCodes:[401,404]});return o},yLt=async({siteId:t,templateId:e,deleteAssets:o=!0})=>{const{data:n}=await Ut.patch(`${Dc}/update-template`,{siteId:t,templateId:e,deleteAssets:o},{plain:!0});return n},z3=async({siteId:t,siteData:e})=>{const{data:o}=await Ut.post(`${Dc}/site/validate`,{siteId:t,data:e});return{errors:o.errors}},vLt=({siteId:t})=>Ut.delete(`${Dc}/${t}/achievements`),l9=t=>{var e;switch((e=t.response)==null?void 0:e.status){case 401:return"builder.unauthorizedSavingNotification";case 409:return"builder.changesOnMultipleDevices";case 403:return"builder.embeddedCodeEditDisabled";default:return"builder.defaultSavingNotification"}},r9=async({websiteId:t,website:e})=>{const{errors:o}=await z3({siteId:t,siteData:e});o.length&&Se({category:"JSON_VALIDATION",message:"Invalid JSON after save",data:{siteData:e,errors:o}})},no=Ex({objectHash(t,e){return`$$index:${e}`||t._id||t.id},arrays:{detectMove:!0,includeValueOnMove:!0},textDiff:{minLength:Number.POSITIVE_INFINITY},cloneDiffValues:!0}),l2=(t,e)=>{const o=v5(t);return no.unpatch(o,e),o},oh=(t,e)=>{const o=v5(t);return no.patch(o,e),o},Md=(t,e)=>no.diff(t,e),d9=({siteData:t})=>{const e=Object.entries(t.languages);return e.length===1?e:e.filter(([n])=>n!==Kt)},c9=({languageDataEntries:t})=>t.every(([,{pages:e}])=>Object.values(e).length===1),u9=({languageDataEntries:t})=>t.some(([,{pages:e}])=>Object.values(e).some(({type:n})=>n===Mn)),p9=({siteData:t})=>t.meta.ecommerceType===Ca,r2=({languageDataEntries:t,elementType:e})=>t.some(([,{elements:o}])=>Object.values(o).some(({type:n})=>n===e)),g9=({languageDataEntries:t})=>t.length>1,m9=({siteData:t})=>{const e=d9({siteData:t}),o=c9({languageDataEntries:e}),n=u9({languageDataEntries:e}),s=p9({siteData:t}),a=r2({languageDataEntries:e,elementType:vl}),l=r2({languageDataEntries:e,elementType:zi}),i=g9({languageDataEntries:e});return{isOnePageSite:o,isUsingBlog:n,isUsingEcommerce:s,isUsingEmbedCode:a,isUsingGallery:l,isUsingMultiLanguage:i}},ji=(t,e,o=!1)=>_5(to(t),e,(n,s)=>{if(Array.isArray(n))return o?[...s,...n]:s}),zc="https://cdn.zyrosite.com/cdn-builder-placeholders",h9=`${zc}/asset-manager`,ln=`${zc}/ecommerce-product`,ua=`${zc}/grid-gallery`,wo=`${zc}/instagram`,_Lt=`${zc}/template`;var bo=(t=>(t.PHYSICAL="physical",t.DIGITAL="digital",t.DONATION="donation",t.BOOKING="booking",t.SERVICE="service",t))(bo||{});const nh={DPD:"dpd",OMNIVA:"omniva",LP_EXPRESS:"lp-express",MANUAL:"manual"},b9={TYPE_CONVERSION_EVENT:"TYPE_CONVERSION_EVENT",TYPE_PAGE_VIEW:"TYPE_PAGE_VIEW"},vu={SUBSCRIBE:"subscribe",BEGIN_CHECKOUT:"begin_checkout",PURCHASE:"purchase",SIGN_UP:"sign_up",CONTACT:"contact",ADD_TO_CART:"add_to_cart"},hi={id:-1,title:"Product name",subtitle:null,description:`This is a sample product description. You can use it to describe your product, from its size, weight, and color to other characteristics like material, and so on.
Make sure you highlight the best qualities and the most important functions that the product has. Make your customers want it and tell them how the product could help make their life easier or simply more beautiful. After you have added your product description in the store settings, it will appear here automatically`,images:[],options:[],product_collections:[],ribbon_text:null,site_product_selection:null,type:{value:bo.PHYSICAL},thumbnail:null,variants:[{id:"",manage_inventory:!1,prices:[{amount:0,currency_code:"USD",sale_amount:null,currency:{code:"USD",decimal_digits:2,template:"$$1",name:"US Dollar",symbol:"$",symbol_native:"$",name_plural:"US dollars",rounding:0,min_amount:0}}],options:[]}],seo_settings:{},purchasable:!0,additional_info:[]},Wn=[{...hi,title:"Classic cap",images:[{url:`${ln}/cap.png`}],thumbnail:`${ln}/cap.png`},{...hi,title:"Face Serum",images:[{url:`${ln}/bottle.png`}],thumbnail:`${ln}/bottle.png`},{...hi,title:"Handmade Vase",images:[{url:`${ln}/vase.png`}],thumbnail:`${ln}/vase.png`},{...hi,title:"Hand Soap",images:[{url:`${ln}/soap.png`}],thumbnail:`${ln}/soap.png`},{...hi,title:"Set of Plates",images:[{url:`${ln}/plates.png`}],thumbnail:`${ln}/plates.png`},{...hi,title:"Sunglasses",images:[{url:`${ln}/sunglasses.png`}],thumbnail:`${ln}/sunglasses.png`},{...hi,title:"Wooden Chair",images:[{url:`${ln}/chair.png`}],thumbnail:`${ln}/chair.png`},{...hi,title:"Wool Sweater",images:[{url:`${ln}/sweater.png`}],thumbnail:`${ln}/sweater.png`}],f9="hours",$c=["BlockEcommerceProduct","BlockEcommerceProductList"],y9="demo_01G0E9P2R0CFTNBWEEFCEV8EG5",of="shopping-cart-items",v9=864e5,$3="site_product_selection",L3="lowest_price_first",Td=250,Cd={[xo.DEFAULT]:"",[xo.PRICE_LTH]:"order=ASC&sort_by=price",[xo.PRICE_HTL]:"order=DESC&sort_by=price",[xo.MOST_RECENT]:"order=DESC&sort_by=created_at"};var Hd=(t=>(t.IMAGE="image",t.VIDEO="video",t))(Hd||{});const ny=[bo.BOOKING,bo.DIGITAL],d2={INVALID:"invalid",CONNECTED:"connected"},_9="https://js.stripe.com/v3/",w9=[nh.DPD,nh.LP_EXPRESS,nh.OMNIVA],ws={fragment:!0,collapseEmptyAttributes:!0},ks=({pageId:t,siteData:e,locale:o=Kt})=>{if(!e||!e.meta||!t)return null;const{meta:n,languages:s}=e,{defaultLocale:a}=n,l=s[o],{pages:i,homePageId:r}=l;return i[t]?o===Kt||o===a?r===t?"/":`/${i[t].slug}`:r===t?`/${o}`:`/${o}/${i[t].slug}`:null},c2={getContentTextBox:t=>({type:"GridTextBox",content:`${t}
`,settings:{styles:{"m-element-margin":"0 0 16px 0",text:"left",align:"flex-start",justify:"flex-start",position:"2/3/4/15"}},animation:{name:"slide",type:"global"}}),getLayoutContentTextBox:t=>({type:"GridTextBox",content:`${t}
`,desktop:{height:30,top:442,left:206,width:812},mobile:{height:30,top:424,left:0,width:Ns},settings:{styles:{"m-element-margin":"0 0 16px 0"}}}),getImage:t=>({rel:"nofollow",type:"GridImage",mobile:{top:40,left:0,width:328,height:320},desktop:{top:40,left:206,width:812,height:344},settings:{alt:t.alt,path:t.path,origin:t.origin,styles:{align:"center",justify:"center","m-element-margin":"0 0 16px 0"},clickAction:"none"},animation:{name:"slide",type:"global"},fullResolutionWidth:3024,fullResolutionHeight:4032})},nc={"row-gap":"16px","row-size":"48px","column-gap":"24px","block-padding":"16px 0","m-block-padding":"56px 16px"},Pd=({mockCategories:t,postsPerPage:e=Eg,postColumnCount:o=i0})=>({type:"BlockBlogList",settings:{postsPerPage:e,postColumnCount:o,categories:[],showAllPosts:!0,showWithoutCategories:!1,fullWidth:!1,mockCategories:t,shownItems:{coverImage:!0,title:!0,description:!0,date:!0,categories:!0,authorFullName:!0,avatar:!0,minutesToRead:!0},styles:{"grid-gap-size":`${l7}px`,"m-grid-gap-size":`${r7}px`,"block-padding":"60px","content-width":`${d7}px`,"cover-object-fit":"contain",rows:10,cols:10,"row-size":nc["row-size"],"row-gap":nc["row-gap"]}},components:[],zindexes:[],background:{current:"color",color:"rgb(255, 255, 255)"}}),nf=()=>({type:"BlockLayout",desktop:{minHeight:500},mobile:{minHeight:140},settings:{styles:{"block-padding":"16px 0 16px 0","m-block-padding":"16px"}},components:[],background:{color:"rgb(255, 255, 255)",current:"color"},zindexes:[]}),k9=()=>({type:"BlockBlogHeader",background:{current:"color",color:"rgb(255, 255, 255)"},settings:{shownItems:{date:!0,categories:!0,authorFullName:!0,avatar:!0,minutesToRead:!0,description:!0},styles:{"block-padding":"45px 30px 45px 30px","m-block-padding":"16px 16px 16px 16px","content-width":"954px",align:"flex-start","text-align":"center"}},animation:{name:"slide",type:"global"},components:[]}),I9=(t,e,o=ie(),n=ie())=>({blockData:{type:"BlockLayout",desktop:{minHeight:500},mobile:{minHeight:140},components:[n,o],zindexes:[n,o],background:{current:"color",color:"rgb(255, 255, 255)"},settings:{styles:{"m-block-padding":nc["m-block-padding"]}}},elements:{[n]:c2.getImage(e),[o]:c2.getLayoutContentTextBox(t)}}),jg=({productId:t=-1,buttonText:e}={})=>({type:"BlockEcommerceProduct",settings:{styles:{"content-width":`${qp}px`,"block-padding":"100px 16px","m-block-padding":nc["m-block-padding"]}},background:{current:"color",color:"rgb(255, 255, 255)"},navigationArrowsColor:"rgb(0, 0, 0)",navigationThumbnailArrowsColor:"rgb(0, 0, 0)",galleryPlacement:"bottom",imageRatio:"contain",imageBorderRadius:"0%",product:{id:t},zindexes:[],isQuantityPickerEnabled:!0,buttonStyle:{"grid-button-primary-color":"rgb(255, 255, 255)","grid-button-primary-color-hover":"rgb(255, 255, 255)","grid-button-primary-background-color":"rgb(0, 0, 0)","grid-button-primary-background-color-active":"rgb(0, 0, 0)","grid-button-primary-background-color-hover":"rgb(29, 30, 32)","grid-button-primary-border-color":"rgb(0, 0, 0)","grid-button-primary-border-color-active":"rgb(0, 0, 0)","grid-button-primary-border-color-hover":"rgb(29, 30, 32)","grid-button-secondary-color":"rgb(46, 47, 49)","grid-button-secondary-color-hover":"rgb(29, 30, 32)","grid-button-secondary-background-color":"rgb(255, 255, 255)","grid-button-secondary-background-color-active":"rgb(255, 255, 255)","grid-button-secondary-background-color-hover":"rgb(241, 241, 241)","grid-button-secondary-border-color":"rgb(255, 255, 255)","grid-button-secondary-border-color-active":"rgb(255, 255, 255)","grid-button-secondary-border-color-hover":"rgb(241, 241, 241)"},textColorVars:{"h1-color":"rgb(26, 26, 26)","h2-color":"rgb(26, 26, 26)","h3-color":"rgb(26, 26, 26)","h4-color":"rgb(26, 26, 26)","h5-color":"rgb(26, 26, 26)","h6-color":"rgb(26, 26, 26)","body-large-color":"rgb(26, 26, 26)","body-color":"rgb(26, 26, 26)"},components:[],...e?{buttonText:e}:{}}),pi=({textAlign:t="left",blockPadding:e="100px 16px",imageRatio:o="contain",isFullWidth:n=!1,columnCountDesktop:s=3,columnGapDesktop:a=24,columnCountMobile:l,columnGapMobile:i,isSortingEnabled:r=!1,productsPerPage:u=6,productCategoryId:p=null,isCategoryListEnabled:g=!1,isTotalProductCountShown:b=!1,isButtonFullWidth:y=!1,buttonDisplay:k=null,imageHoverEffect:I=null,isButtonEnabled:E=!1,isListCentered:T=!1,buttonStyle:P={},buttonBorderWidth:z=null,productSearch:L})=>({type:"BlockEcommerceProductList",settings:{styles:{textAlign:t,"content-width":`${qp}px`,"block-padding":e,"m-block-padding":nc["m-block-padding"],...I&&{imageHoverEffect:I}}},background:{current:"color",color:"rgb(255, 255, 255)"},imageRatio:o,...(s||a)&&{desktop:{...s&&{columnCount:s},...a&&{columnGap:a}}},...(l||i)&&{mobile:{...l&&{columnCount:l},...i&&{columnGap:i}}},isFullWidth:n,...r&&{productSorting:{enabled:!0,textColor:"#000",sortingOptions:[{id:"default",label:"Default",value:"",isEnabled:!0},{id:"priceLTH",label:"Price (low to high)",value:"order=ASC&sort_by=price",isEnabled:!0},{id:"priceHTL",label:"Price (high to low)",value:"order=DESC&sort_by=price",isEnabled:!0},{id:"mostRecent",label:"Most recent",value:"order=DESC&sort_by=created_at",isEnabled:!0}]}},...L&&{productSearch:L},productsPerPage:u,...p&&{productCategoryId:p},isCategoryListEnabled:g,isTotalProductCountShown:b,zindexes:[],textColorVars:{"h1-color":"rgb(26, 26, 26)","h2-color":"rgb(26, 26, 26)","h3-color":"rgb(26, 26, 26)","h4-color":"rgb(26, 26, 26)","h5-color":"rgb(26, 26, 26)","h6-color":"rgb(26, 26, 26)","body-large-color":"rgb(26, 26, 26)","body-color":"rgb(26, 26, 26)"},buttonStyle:{"grid-button-primary-color":"rgb(255, 255, 255)","grid-button-primary-color-hover":"rgb(255, 255, 255)","grid-button-primary-background-color":"rgb(0, 0, 0)","grid-button-primary-background-color-active":"rgb(0, 0, 0)","grid-button-primary-background-color-hover":"rgb(29, 30, 32)","grid-button-primary-border-color":"rgb(0, 0, 0)","grid-button-primary-border-color-active":"rgb(0, 0, 0)","grid-button-primary-border-color-hover":"rgb(29, 30, 32)","grid-button-secondary-color":"rgb(46, 47, 49)","grid-button-secondary-color-hover":"rgb(29, 30, 32)","grid-button-secondary-background-color":"rgb(255, 255, 255)","grid-button-secondary-background-color-active":"rgb(255, 255, 255)","grid-button-secondary-background-color-hover":"rgb(241, 241, 241)","grid-button-secondary-border-color":"rgb(255, 255, 255)","grid-button-secondary-border-color-active":"rgb(255, 255, 255)","grid-button-secondary-border-color-hover":"rgb(241, 241, 241)",...P},...k&&{buttonDisplay:k},...z&&{buttonBorderWidth:z},isButtonEnabled:E,isButtonFullWidth:y,ribbonStyle:{"ribbon-color":"rgb(255, 255, 255)","ribbon-background-color":"rgb(29, 30, 32)"},components:[],...T&&{isListCentered:T}}),S9=(t=ie())=>({pageData:{type:Uo,blocks:[t]},blocks:{[t]:{...jg()}}}),O3=({title:t,gridTextBoxElementId:e=ie()})=>({blockData:{type:"BlockLayout",mobile:{minHeight:170},desktop:{minHeight:234},settings:{styles:{"block-padding":"16px 0 16px 0","m-block-padding":"16px"}},zindexes:[e],background:{color:"rgb(255, 255, 255)",current:"color"},components:[e]},elements:{[e]:{type:"GridTextBox",mobile:{top:64,left:0,width:328,height:46},content:`${t} `,desktop:{top:80,left:309,width:606,height:72},settings:{styles:{text:"center",align:"flex-start",justify:"flex-start","m-element-margin":"0 0 16px 0"}},animation:{name:"slide",type:"global"}}}}),E9=(t=ie())=>({blockData:{type:"BlockLayout",mobile:{minHeight:1455},desktop:{minHeight:1925},settings:{styles:{"block-padding":"16px 0 16px 0","m-block-padding":"16px"}},zindexes:[t],background:{color:"rgb(255, 255, 255)",current:"color"},components:[t]},elements:{[t]:{type:"GridGallery",images:[{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-aeae-ss-ae---2848289-m5kpo846zzf0bgek-AE0E3LX1KZuDK17O.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-edward-jenner-4252525-m5kpo84naqf4kbo6-A85D7Pk72PuR98aN.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-graphicgumcom-1289672-ylen74xpl8u9a0rn-m2W1OV5L2kHblob7.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-ilya-galica-5271593-ar0ep1qeb1s9kwnj-Yg27E3gErJhgP4yO.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-carlos-montelara-5152692-y4llnpbqpnclvzxo-Yan7eP3egJtD3jeo.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-lisa-fotios-4644397-d95mnzob1zhx54ov-mP4Z6Je6j2c3Xxaw.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-anna-shvets-4557398-avlpox4q0ku594kg-dWxn64G6erF5laj3.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-damian-apanasowicz-4185556-y4llnpbn95sznnjk-AzGOab1Q6WsOjBPD.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-thiago-giardini-5815066-ar0ep1qv43t1kger-YrD3O7zOlBUjOwNa.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-charlotte-may-5825574-aopda47pbotbyq5l-mjEzjB0j9JUO1K48.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-mitchell-luo-3685207-a3qbylnzq0trx2gq-YbNb68MWQof74BQ7.jpg",origin:"other"},{alt:"",path:"https://assets.zyrosite.space/AR0eprE7RRhpVzDz/pexels-bruno-cervera-6033461-yg27e4gdebtgb9o7-mePyWM0W3lSkywGL.jpg",origin:"other"}],mobile:{top:16,left:0,width:328,height:1417,columnGap:12,columnCount:2},desktop:{top:64,left:103,width:1018,height:1746,columnGap:"16",columnCount:"3"},settings:{layout:"masonry",styles:{"m-element-margin":"0 0 16px 0"},imageClickAction:"lightbox"},animation:{name:"slide",type:"global"}}}}),x9=({imageData:t,imageElementId:e=ie()})=>({blockData:{type:"BlockLayout",mobile:{minHeight:400},desktop:{minHeight:640},settings:{styles:{"block-padding":"16px 0 16px 0","m-block-padding":"16px"}},zindexes:[e],background:{color:"rgb(255, 255, 255)",current:"color"},components:[e]},elements:{[e]:{rel:"nofollow",type:"GridImage",mobile:{top:40,left:4,width:320,height:320},desktop:{top:80,left:372,width:480,height:480},...t,settings:{alt:"Bright living room with modern inventory",...t.settings,styles:{align:"center",justify:"center","m-element-margin":"0 0 16px 0"},clickAction:"none"}}}}),T9=()=>({type:"BlockStickyBar",desktop:{minHeight:40},mobile:{minHeight:40},settings:{styles:{"block-padding":"0","m-block-padding":"0 16px"}},components:[],background:{color:"rgb(255, 255, 255)",current:"color"},zindexes:[],items:[{type:"text",content:'Add your promotional text...
'}]}),sf=({blocks:t})=>Object.fromEntries(Object.entries(t).filter(([,e])=>yc.includes(e.type))),af=({elements:t})=>Object.fromEntries(Object.entries(t).filter(([,e])=>!vc.includes(e.type))),Wg=({blocks:t,elements:e})=>{const o=sf({blocks:t}),n=af({elements:e});return[...Object.values(o),...Object.values(n)].find(s=>{var a;return((a=s.animation)==null?void 0:a.type)===Ls})},iy=({elements:t,itemWithAnimation:e})=>Object.fromEntries(Object.entries(t).map(([o,n])=>vc.includes(n.type)?[o,n]:[o,{...n,animation:{name:e.animation.name,type:Ls}}])),C9=({blocks:t,itemWithAnimation:e})=>Object.fromEntries(Object.entries(t).map(([o,n])=>yc.includes(n.type)?[o,{...n,animation:{name:e.animation.name,type:Ls}}]:[o,n])),P9=/^(\/\/|http:\/\/|https:\/\/|#)?(.*)/,B9=/^(?:\w+:)?\/\/([^\s.]+\.\S{2}|localhost[\d:?]*)\S*$/,sy=/^[\p{L}\p{N}+._&-]{1,80}@[\p{L}\p{N}.-]{1,80}\.[A-Za-z]{1,15}$/u,ay=/^\+*\({0,1}\d{1,4}\){0,1}[\d./s-]*$/,A9=/-(.*)/,D9=/^\d+$/,z9=/^\/[^./]+(\.[A-Za-z]+)?$/,$9=/^([\w ().-]+)\.([\dA-Za-z]+)$/,ly=/^(http:\/\/www\.|https:\/\/www\.|http:\/\/|https:\/\/)/,ry=(t="")=>{let e=decodeURI(t).trim();return[/\s/g,/^tel:/,/^mailto:/].forEach(n=>{e=e.replace(n,"")}),e},R3=t=>sy.test(t),dy=(t="")=>{const e=ry(t);return R3(e)?{url:`mailto:${e}`,isUrlValid:!0}:{url:t,isUrlValid:!1}},M3=(t="")=>{const e=ry(t);return ay.test(e)?{url:`tel:${e}`,isUrlValid:!0}:{url:t,isUrlValid:!1}},u2=(t="")=>B9.test(t),H3=(t="",e=!1)=>{const o={url:t,isUrlValid:!1};if(!t||/^[\dA-Za-z]+$/.test(t))return o;if(t[0]==="#")return{url:t,isUrlValid:!0};if(M3(t).isUrlValid||dy(t).isUrlValid)return o;try{const n=/^(http:\/\/|https:\/\/)/.test(t),s=e?"http://":"https://",a=new URL(n?t:`${s}${t}`),l=t.endsWith("/")?a.href:a.href.replace(/\/$/,""),r=l.match(P9)[1];if(["http://","https://"].includes(r)&&u2(l))return{url:l,isUrlValid:u2(l)}}catch{return o}return o},Lc=(t="")=>({path:xx(t,{lower:!0,strict:!0,trim:!1}),isPathValid:!0}),lf=t=>{if(!t)return{path:t,isPathValid:!0};const{path:e}=Lc(t);return{path:e||ie(),isPathValid:!0}},L9=(t="")=>({htmlId:t.replace(/[^\d a-z-]/gi,"").replace(/^[\W\d]+/,"").replace(/\s/g,"-").toLowerCase(),isUrlValid:!0}),O9=(t="")=>{const e=ry(t);return e&&ay.test(e)?{url:`tel:${e}`,isUrlValid:!0}:{url:t,isUrlValid:!1}},R9=(t="")=>t?`https://maps.google.com/maps?q=${encodeURIComponent(t)}&t=m&z=13&ie=UTF8&output=embed`:"",M9=(t="")=>t?decodeURIComponent(t.split("?q=")[1].split("&t=")[0]):"",Hr=t=>t==null?void 0:t.includes("/generated/generated-"),Aa=(t,e)=>Hr(t)?`generated/${e}`:e,N3=({initialSlug:t,existingSlugs:e,slugSuffix:o})=>{let n=t,s=Xs({stringToMatch:lf(`${n}${o}`).path,strings:e});for(;s.length>Zs;){const a=s.length-Zs;n=n.substring(0,n.length-a),s=Xs({stringToMatch:lf(`${n}${o}`).path,strings:e})}return s};var m5,h5,b5,f5,y5;const G3=((h5=(m5=window==null?void 0:window.location)==null?void 0:m5.hostname)==null?void 0:h5.includes(".hostinger.dev"))||((f5=(b5=window==null?void 0:window.location)==null?void 0:b5.hostname)==null?void 0:f5.includes(".hostinger.io"))||((y5=window==null?void 0:window.location)==null?void 0:y5.hostname.includes("zyro.space")),p2=(t,e)=>t.find(o=>o.linkedPageId===e),H9=({locale:t=Kt,siteData:e,itemData:o,isHidden:n=!1})=>{Se({category:"ADD_NAVIGATION_ITEM",data:{itemData:o,isHidden:n},level:"debug",type:"debug"});const s=no.clone(e),a=o.subItems.filter(l=>l.linkType!=="Page");return s.languages[t].nav.push({...o,navItemId:o.navItemId??ie(),isHidden:n,subItems:a}),s},F3=({siteData:t,pageId:e,blockId:o=ie(),blockData:n,previousBlockId:s,elements:a,blocks:l,slideshowBlockId:i,slideMetadata:r,locale:u=Kt})=>{var I,E,T,P,z,L,D,$;Se({category:"ADD_BLOCK",data:{pageId:e,blockId:o,blockData:n,previousBlockId:s,elements:a,blocks:l,slideshowBlockId:i,slideMetadata:r},level:"debug",type:"debug"});const p=no.clone(t),g=(D=(L=(z=(P=(T=(E=(I=window==null?void 0:window.__VUE_DEVTOOLS_GLOBAL_HOOK__)==null?void 0:I.apps)==null?void 0:E[0])==null?void 0:T.app)==null?void 0:P.config)==null?void 0:z.globalProperties)==null?void 0:L.$store)==null?void 0:D.getters["user/isZyroUser"];let b={...n},y={...a};const k=Wg({blocks:p.languages[u].blocks,elements:p.languages[u].elements});if(k&&(yc.includes(n.type)&&(b={...b,animation:{name:k.animation.name,type:Ls}}),y=iy({elements:y,itemWithAnimation:k})),p.languages[u].elements={...p.languages[u].elements,...y},p.languages[u].blocks={...p.languages[u].blocks,...l,[o]:b},($=p.languages[u].blocks[o])!=null&&$.htmlId&&delete p.languages[u].blocks[o].htmlId,Object.keys(b).length||(jt(new Error("Empty block data"),{tags:{errorType:"Empty block"}}),G3&&g&&console.error(`EMPTY BLOCK - ${o}: addBlock function`)),i){const A=p.languages[u].blocks[i];p.languages[u].blocks[i]={...A,slides:[...A.slides,{blockId:o,...r}]}}else if(e){const A=p.languages[u].pages[e].blocks;let M=A.length;s==="header"?M=0:A.indexOf(s!==-1)&&(M=A.indexOf(s)+1),p.languages[u].pages[e].blocks.splice(M,0,o)}return!p.meta[Zi]&&$c.includes(n==null?void 0:n.type)&&(p.meta[Zi]=Ca),p},cy=({siteData:t,blockId:e,locale:o=Kt})=>{var l,i,r,u,p,g,b,y;Se({category:"REMOVE_BLOCK",data:e,level:"debug",type:"debug"});const n=no.clone(t),s=(b=(g=(p=(u=(r=(i=(l=window==null?void 0:window.__VUE_DEVTOOLS_GLOBAL_HOOK__)==null?void 0:l.apps)==null?void 0:i[0])==null?void 0:r.app)==null?void 0:u.config)==null?void 0:p.globalProperties)==null?void 0:g.$store)==null?void 0:b.getters["user/isZyroUser"],a=[e,...n.languages[o].blocks[e].type!=="BlockImageSlideshow"?((y=n.languages[o].blocks[e].slides)==null?void 0:y.map(k=>k.blockId))||[]:[]];return a.flatMap(k=>n.languages[o].blocks[k].components).forEach(k=>{delete n.languages[o].elements[k]}),n.languages[o].blocks=Object.entries(n.languages[o].blocks).reduce((k,[I,E])=>a.includes(I)?k:(Object.keys(E).length||(jt(new Error("Empty block data"),{tags:{errorType:"Empty block"}}),G3&&s&&console.error(`EMPTY BLOCK - ${e}: removeBlock function`)),{...k,[I]:{...E,...E.slides&&{slides:E.slides.filter(T=>T.blockId!==e)}}}),{}),n.languages[o].pages=Object.entries(n.languages[o].pages).reduce((k,[I,E])=>{var T;return{...k,[I]:{...E,blocks:(T=E.blocks)==null?void 0:T.filter(P=>P!==e)}}},{}),n},Nr=({siteData:t,blockId:e,slot:o,fromLocale:n})=>{var p;Se({category:"CLONE_BLOCK",data:{blockId:e,slot:o},level:"debug",type:"debug"});const s=no.clone(t.languages[n].blocks[e]);s.initialBlockId=e;const a={},l=[],i=s.zindexes??[],r={};s.components&&((p=s.components)==null||p.forEach(g=>{const b=ie();t.languages[n].elements[g]&&(a[b]=no.clone(t.languages[n].elements[g]),a[b].initialElementId=g,l.push(b),i[i.indexOf(g)]=b)}));const u={...s,components:l,zindexes:i,...o&&{slot:o}};return{newBlockId:ie(),newBlock:u,newElements:a,newBlocks:r}},V3=({siteData:t,elementId:e,locale:o=Kt})=>{const n=no.clone(t);return n.languages[o].blocks=Object.entries(n.languages[o].blocks).reduce((s,[a,l])=>{let i=l;return l.components&&l.zindexes&&(i={...l,components:l.components.filter(r=>r!==e),zindexes:l.zindexes.filter(r=>r!==e)}),{...s,[a]:i}},{}),delete n.languages[o].elements[e],n},pl=({locale:t=Kt,siteData:e,pageId:o,pageData:n,blocks:s,elements:a,navigationItem:l,isPageTypeEcommerce:i=!1})=>{const r={...n};Se({category:"ADD_PAGE",data:{pageId:o,pageData:r,blocks:s,elements:a,navigationItem:l},level:"debug",type:"debug"});let u=no.clone(e),p={...s},g={...a};u.languages[t].pages={...u.languages[t].pages,[o]:r};const b=Wg({blocks:u.languages[t].blocks,elements:u.languages[t].elements});return b&&(p=C9({blocks:p,itemWithAnimation:b}),g=iy({elements:g,itemWithAnimation:b})),p&&(u.languages[t].blocks={...u.languages[t].blocks,...p}),g&&(u.languages[t].elements={...u.languages[t].elements,...g}),l&&(u=H9({locale:t,siteData:u,itemData:{...l,linkedPageId:o},isHidden:l.isHidden})),!u.meta[Zi]&&i&&(u.meta[Zi]=Ca),u},nl=({siteData:t,pageId:e,locale:o=Kt})=>{var a,l;Se({category:"REMOVE_PAGE",data:{pageId:e},level:"debug",type:"debug"});let n=no.clone(t);(l=(a=n.languages[o].pages[e])==null?void 0:a.blocks)==null||l.forEach(i=>{n=cy({siteData:n,blockId:i,locale:o})}),delete n.languages[o].pages[e];const s=n.languages[o].nav.reduce((i,r)=>{if(r.linkedPageId!==e&&!r.subItems)return[...i,r];if(r.linkedPageId!==e){const p=r.subItems.filter(({linkedPageId:g})=>g!==e);return[...i,{...r,subItems:p}]}if(!r.subItems)return i;const u=r.subItems.filter(({linkedPageId:p})=>p!==e);return[...i,...u]},[]);return n.languages[o].nav=s,n},N9=({siteData:t,pageId:e,fromLocale:o=Kt,toLocale:n=Kt})=>{Se({category:"CLONE_PAGE",data:e,level:"debug",type:"debug"});const s=no.clone(t.languages[o].pages[e]),a=[];let l={},i={};s.blocks.forEach(T=>{const{newBlockId:P,newBlock:z,newElements:L,newBlocks:D}=Nr({siteData:t,blockId:T,slot:null,fromLocale:o});l={...l,...D,[P]:z},i={...i,...L},a.push(P)});const r="-copy",u=s.name.substring(0,Zs-r.length),p=Object.values(t.languages[o].pages).map(({slug:T})=>T),g={...s,blocks:a,name:`${s.name} Copy${n!==o?` (${n})`:""}`,slug:N3({initialSlug:u,existingSlugs:p,slugSuffix:r})};if(s.type===Mn)return{clonedPageData:g,clonedBlocks:l,clonedElements:i,clonedPageNavigationItem:null};const{nav:b}=t.languages[o],y=b.flatMap(({subItems:T})=>T).filter(T=>T),k=p2(b,e)||p2(y,e),{navItemId:I,...E}=k;return{clonedPageData:g,clonedBlocks:l,clonedElements:i,clonedPageNavigationItem:E}},U3=({locale:t=Kt,siteData:e,postTitle:o,postDescription:n,postContent:s,postThumbnail:a,isDraft:l})=>{Se({category:"ADD_BLOG_POST_TEMPLATE",data:{isDraft:l},level:"debug",type:"debug"});const i=no.clone(e),r=ie(),u=ie(),p=ie(),{blockData:g,elements:b}=I9(s,a);let y={...b};const k=Wg({blocks:i.languages[t].blocks,elements:i.languages[t].elements});return k&&(y=iy({elements:y,itemWithAnimation:k})),{siteDataWithBlogPostPage:pl({locale:t,siteData:i,pageId:r,pageData:{type:"blog",name:o,slug:Xs({stringToMatch:MP,strings:Object.values(i.languages[t].pages).map(({slug:E})=>E)}),blocks:[u,p],meta:{title:o,description:n,ogImageOrigin:a.origin,ogImagePath:a.path,ogImageAlt:a.alt},isDraft:l,coverImageOrigin:a.origin,coverImagePath:a.path,coverImageAlt:a.alt,date:new Date().toISOString(),categories:[],minutesToRead:"1"},blocks:{[u]:k9(),[p]:g},elements:{...y}}),pageId:r}},G9=({siteData:t,productData:e,productBlockStylesFromTheme:o={},locale:n=Kt})=>{const s=no.clone(t),a=ie(),l=ie();return{siteDataWithLegacyProductPage:pl({locale:n,siteData:s,pageId:a,pageData:{type:un,name:e==null?void 0:e.title,blocks:[l],productId:e.id},blocks:{[l]:{...jg({productId:e.id}),...o}}}),productId:e.id}},sd=({languageData:t,pageType:e})=>{if(!Object.values(t.pages).some(({type:u})=>u===e))return t;const n=Object.fromEntries(Object.entries(t.pages).filter(([,u])=>u.type===e)),s=Object.keys(n).flatMap(u=>n[u].blocks),a=s.flatMap(u=>t.blocks[u].components).filter(u=>u),l=Object.fromEntries(Object.entries(t.pages).filter(([,u])=>u.type!==e)),i=Object.fromEntries(Object.entries(t.blocks).filter(([u])=>!s.includes(u))),r=Object.fromEntries(Object.entries(t.elements).filter(([u])=>!a.includes(u)));return{...t,pages:l,blocks:i,elements:r}},F9=(t,e)=>{const o=({linkType:a,linkedPageId:l,href:i})=>{var u,p;const r=(p=(u=t.languages[e].pages)==null?void 0:u[l])==null?void 0:p.type;return r===Uo||r===un?i:a===oe.ANCHORED_SECTION?`${e===Kt||e===t.meta.defaultLocale?"":`/${e}`}${i}`:a===oe.PAGE&&l?ks({locale:e,siteData:t,pageId:l})??i:i},n=Object.entries(t.languages[e].elements).map(a=>{const[l,i]=a,{type:r,content:u}=i;if(r===Po){const p=()=>b=>{_s(b,"element",y=>{y.properties.href&&(y.properties.href=o({href:y.properties.href,linkType:y.properties.href.includes("#")&&!URL.canParse(y.properties.href)?oe.ANCHORED_SECTION:oe.PAGE,linkedPageId:y.properties.dataPageId}))})},g=vs().data("settings",ws).use(p).processSync(u).toString();return[l,{...i,content:g}]}return r===Hn?[l,{...i,href:o({href:i.href,linkType:i.linkType,linkedPageId:i.linkedPageId})}]:r===_n&&i.href?[l,{...i,href:o({href:i.href,linkType:i.href.includes("#")&&!URL.canParse(i.href)?oe.ANCHORED_SECTION:oe.PAGE,linkedPageId:i.linkedPageId})}]:a}),s=t.languages[e].nav.map(a=>({...a,href:o({href:a.href,linkType:a.innerLinkType,linkedPageId:a.innerLinkPageId})}));return t.languages[e].elements=Object.fromEntries(n),t.languages[e].nav=s,t},V9=(t,e)=>{const o=to(t);return e.forEach(n=>{const s=ie();o.elements=Object.fromEntries(Object.entries(o.elements).map(([a,l])=>{const i=a===n;return[i?s:a,{...l,...i&&{initialElementId:n}}]})),o.blocks=Object.fromEntries(Object.entries(o.blocks).map(([a,l])=>[a,{...l,...l.components?{components:l.components.map(i=>i===n?s:i)}:{},...l.zindexes?{zindexes:l.zindexes.map(i=>i===n?s:i)}:{}}]))}),o},uy=t=>{let e="";return t.nodeType===Node.TEXT_NODE&&(e+=t.textContent),t.childNodes&&t.childNodes.forEach(o=>{e+=uy(o)}),e},j3=t=>`${NC}/${t}`,W3=t=>`${GC}/${t}`,ih=(t="",e="")=>`${t}${e}`,py=t=>{localStorage.setItem(`${v4}-${t}`,"1")},U9=t=>localStorage.getItem(`${v4}-${t}`),q3=(t,e)=>!U9(e)&&t,j9=({sortType:t,collectionId:e,sortedProductsFromStore:o,allProducts:n,totalProductCount:s})=>t||e?!!(o!=null&&o.length&&(o==null?void 0:o.length)===s):s!==0&&(n==null?void 0:n.length)===s,Oc="https://api-ecommerce.hostinger.com/store",W9=async t=>{const{data:e}=await Ut.get(`${Oc}/${t}/settings`);return e},Bd=async(t,e={})=>{const{sort:o,collectionId:n,isHidden:s,limit:a,offset:l,productId:i}=e,r=new URLSearchParams(o);n&&r.set("collection_ids[]",n),s&&r.set("is_hidden",s.toString()),a&&r.set("limit",a.toString()),typeof l=="number"&&a&&r.set("offset",l.toString()),i&&r.set("ids[]",i);const{data:u}=await Ut.get(`${Oc}/${t}/products?${r.toString()}`);return{products:u.products,count:u.count}},q9=async t=>{const{data:e}=await Ut.get(`${Oc}/${t}/variants`,{params:{fields:"inventory_quantity"}});return e==null?void 0:e.variants},Y9=async t=>{const{data:e}=await Ut.get(`${Oc}/${t}/collections`);return e.collections},K9=async t=>await(await fetch(`${Oc}/${t}/products/seo-settings`)).json(),Ci=t=>(t==null?void 0:t.ecommerceStoreId)??(t==null?void 0:t.demoEcommerceStoreId)??y9,gy="https://api-ecommerce.hostinger.com/admin",g2=async(t,e)=>{const{data:o}=await Ut.post(`${gy}/products/seo-settings`,{products:e},{headers:{"x-ecommerce-id":t}});return o==null?void 0:o.products},Z9=async t=>{const{data:e}=await Ut.get(`${gy}/store/settings`,{headers:{"x-ecommerce-id":t}});return e},Q9=async t=>{const{data:e}=await Ut.get(`${gy}/payment-providers`,{headers:{"x-ecommerce-id":t}});return e},rf=(t,e)=>{const o=[],n=t.length;let s=0;for(;sn.localeId===t);return e.unshift(t),o.fallback?Z3(o.fallback,e):e}async function Q3(t){const e=Z3(t),o=await Promise.all(e.map(s=>lD(`./translations/${s}.json`))),n=to(K3);return o.forEach(s=>{_5(n,s,aD)}),n}function lD(t){switch(t){case"./translations/ar_AR":case"./translations/ar_AR.json":return R(()=>import("../chunk/ar_AR-1738332614265.js"),[]);case"./translations/cs_CZ":case"./translations/cs_CZ.json":return R(()=>import("../chunk/cs_CZ-1738332614265.js"),[]);case"./translations/da_DK":case"./translations/da_DK.json":return R(()=>import("../chunk/da_DK-1738332614265.js"),[]);case"./translations/de_DE":case"./translations/de_DE.json":return R(()=>import("../chunk/de_DE-1738332614265.js"),[]);case"./translations/el_GR":case"./translations/el_GR.json":return R(()=>import("../chunk/el_GR-1738332614265.js"),[]);case"./translations/en_AU":case"./translations/en_AU.json":return R(()=>import("../chunk/en_AU-1738332614265.js"),[]);case"./translations/en_CA":case"./translations/en_CA.json":return R(()=>import("../chunk/en_CA-1738332614265.js"),[]);case"./translations/en_GB":case"./translations/en_GB.json":return R(()=>import("../chunk/en_GB-1738332614265.js"),[]);case"./translations/en_IN":case"./translations/en_IN.json":return R(()=>import("../chunk/en_IN-1738332614265.js"),[]);case"./translations/en_US":case"./translations/en_US.json":return R(()=>import("../chunk/en_US-1738332614265.js"),[]);case"./translations/es_AR":case"./translations/es_AR.json":return R(()=>import("../chunk/es_AR-1738332614265.js"),[]);case"./translations/es_BO":case"./translations/es_BO.json":return R(()=>import("../chunk/es_BO-1738332614265.js"),[]);case"./translations/es_CL":case"./translations/es_CL.json":return R(()=>import("../chunk/es_CL-1738332614265.js"),[]);case"./translations/es_CO":case"./translations/es_CO.json":return R(()=>import("../chunk/es_CO-1738332614265.js"),[]);case"./translations/es_EC":case"./translations/es_EC.json":return R(()=>import("../chunk/es_EC-1738332614265.js"),[]);case"./translations/es_ES":case"./translations/es_ES.json":return R(()=>import("../chunk/es_ES-1738332614265.js"),[]);case"./translations/es_MX":case"./translations/es_MX.json":return R(()=>import("../chunk/es_MX-1738332614265.js"),[]);case"./translations/es_PE":case"./translations/es_PE.json":return R(()=>import("../chunk/es_PE-1738332614265.js"),[]);case"./translations/es_UY":case"./translations/es_UY.json":return R(()=>import("../chunk/es_UY-1738332614265.js"),[]);case"./translations/es_VE":case"./translations/es_VE.json":return R(()=>import("../chunk/es_VE-1738332614265.js"),[]);case"./translations/fi_FI":case"./translations/fi_FI.json":return R(()=>import("../chunk/fi_FI-1738332614265.js"),[]);case"./translations/fr_FR":case"./translations/fr_FR.json":return R(()=>import("../chunk/fr_FR-1738332614265.js"),[]);case"./translations/he_IL":case"./translations/he_IL.json":return R(()=>import("../chunk/he_IL-1738332614265.js"),[]);case"./translations/hi_IN":case"./translations/hi_IN.json":return R(()=>import("../chunk/hi_IN-1738332614265.js"),[]);case"./translations/id_ID":case"./translations/id_ID.json":return R(()=>import("../chunk/id_ID-1738332614265.js"),[]);case"./translations/it_IT":case"./translations/it_IT.json":return R(()=>import("../chunk/it_IT-1738332614265.js"),[]);case"./translations/ja_JP":case"./translations/ja_JP.json":return R(()=>import("../chunk/ja_JP-1738332614265.js"),[]);case"./translations/lt_LT":case"./translations/lt_LT.json":return R(()=>import("../chunk/lt_LT-1738332614265.js"),[]);case"./translations/ms_MY":case"./translations/ms_MY.json":return R(()=>import("../chunk/ms_MY-1738332614265.js"),[]);case"./translations/nb_NO":case"./translations/nb_NO.json":return R(()=>import("../chunk/nb_NO-1738332614265.js"),[]);case"./translations/nl_NL":case"./translations/nl_NL.json":return R(()=>import("../chunk/nl_NL-1738332614265.js"),[]);case"./translations/pl_PL":case"./translations/pl_PL.json":return R(()=>import("../chunk/pl_PL-1738332614265.js"),[]);case"./translations/pt_BR":case"./translations/pt_BR.json":return R(()=>import("../chunk/pt_BR-1738332614265.js"),[]);case"./translations/pt_PT":case"./translations/pt_PT.json":return R(()=>import("../chunk/pt_PT-1738332614265.js"),[]);case"./translations/ro_RO":case"./translations/ro_RO.json":return R(()=>import("../chunk/ro_RO-1738332614265.js"),[]);case"./translations/ru_RU":case"./translations/ru_RU.json":return R(()=>import("../chunk/ru_RU-1738332614265.js"),[]);case"./translations/sv_SE":case"./translations/sv_SE.json":return R(()=>import("../chunk/sv_SE-1738332614265.js"),[]);case"./translations/th_TH":case"./translations/th_TH.json":return R(()=>import("../chunk/th_TH-1738332614265.js"),[]);case"./translations/tr_TR":case"./translations/tr_TR.json":return R(()=>import("../chunk/tr_TR-1738332614265.js"),[]);case"./translations/uk_UA":case"./translations/uk_UA.json":return R(()=>import("../chunk/uk_UA-1738332614265.js"),[]);case"./translations/vi_VN":case"./translations/vi_VN.json":return R(()=>import("../chunk/vi_VN-1738332614265.js"),[]);case"./translations/zh_CN":case"./translations/zh_CN.json":return R(()=>import("../chunk/zh_CN-1738332614265.js"),[]);default:return new Promise(function(e,o){(typeof queueMicrotask=="function"?queueMicrotask:setTimeout)(o.bind(null,new Error("Unknown variable dynamic import: "+t)))})}}const Er=Rc.find(({localeId:t})=>t==="en_GB");function Sa(t){return Rc.find(e=>e.code===t)}function X3(t){return Rc.find(e=>e.iso===t)}function m2(t={}){var a;const o={...{countryCodeOnly:!1},...t},n=((a=navigator.languages)==null?void 0:a[0])||navigator.language;return n?o.countryCodeOnly?n.trim().split(/-|_/)[0]:n.trim():void 0}function rD(){const t=X3(m2())||Sa(m2({countryCodeOnly:!0}));return t==null?void 0:t.code}const dD={de:"de","com.ar":"es",co:"co",es:"es",mx:"mx",fr:"fr",it:"it","com.br":"pt",nl:"nl"};function cD(){const t=Sa(oy())||Sa(rD());return(t==null?void 0:t.code)||Er.code}let my=cD();const Zl=Tx({legacy:!1,locale:my,fallbackLocale:Er.code,messages:{[Er.code]:K3},silentTranslationWarn:!0}),h2=[Er.code];function sh(t){Zl.global.locale.value=t,D3(t)}function ic(t){const e=Sa(t);return e?h2.includes(t)?(Zl.global.locale.value!==t&&sh(t),Promise.resolve(t)):Q3(e.localeId).then(o=>(Zl.global.setLocaleMessage(t,o),h2.push(t),sh(t),Promise.resolve(t))):(sh(Zl.global.fallbackLocale),Promise.resolve(Zl.global.fallbackLocale))}const uD=t=>{if(Y0())return;const e=dD[t];if(!e){ic(Er.code);return}my=Sa(e).code,ic(Sa(e).code)};function b2(t){const e=X3(t)||Sa(t);return e?Q3(e.localeId):null}const ah=async()=>{Y0()&&ic(my)},pD=[d2.INVALID,d2.CONNECTED,null],me=Wo(en.ECOMMERCE,()=>{const{state:t,getters:e,dispatch:o}=nt(),n=Bt(),s=fo(),a=C(!0),l=C(!1),i=C(!1),r=C({global:!1}),u=C({}),p=C({}),g=C([]),b=C(0),y=C([]),k=C(!1),I=C(""),E=C([]),T=C([]),P=C(""),z=C(""),L=c(()=>n.siteMeta.ecommerceType===Ca),D=c(()=>L.value&&n.siteMeta.ecommerceStoreId),$=c(()=>[...g.value,...y.value]),A=c(()=>Object.entries(t.ecommerce.productMetaUpdates).map(([kt,Pt])=>{const Dt=T.value.find(({id:re})=>re===kt),Ot=(Dt==null?void 0:Dt.seo_settings)||{},Wt=Pt.seo_settings||{};return{id:kt,seo_settings:{...Ot,...Wt}}})),M=c(()=>T.value.reduce((kt,Pt)=>{const Dt=A.value.find(Ot=>Ot.id===Pt.id);return[...kt,Dt||Pt]},[])),U=c(()=>n.site.ecommerceSeoChanges||[]),Y=c(()=>Ci(e.siteMeta)),F=c(()=>e.defaultLocale),W=c(()=>T.value.map(kt=>{var Ot,Wt;const Pt=(Ot=kt.seo_settings)==null?void 0:Ot.slug;return((Wt=t.ecommerce.productMetaUpdates[kt.id])==null?void 0:Wt.slug)||Pt})),V=c(()=>{const kt=Do(FC);return n.isLegacyProductPagesAdded?!1:kt?!(kt==="true"):!0}),K=kt=>{I.value=kt},Z=kt=>{var Dt;const Pt=(Dt=M.value.find(Ot=>Ot.seo_settings.slug===kt))==null?void 0:Dt.id;Pt&&K(Pt)},N=kt=>{(!g.value.length||kt.length>g.value.length)&&(g.value=kt);const Pt=g.value.map(Dt=>{const Ot=kt.find(Wt=>Wt.id===Dt.id);return Ot?{...Dt,...Ot}:Dt});if(V.value){const Dt=kt.filter(Ot=>!(Pt!=null&&Pt.some(Wt=>Wt.id===Ot.id)));g.value=[...Pt,...Dt];return}g.value=Pt},X=(kt,Pt)=>{const Dt=kt.filter(Ot=>{var Wt;return!((Wt=u.value[Pt])!=null&&Wt.some(re=>re.id===Ot.id))});u.value[Pt]=[...u.value[Pt]||[],...Dt]},et=({products:kt,sort:Pt,collectionId:Dt,count:Ot})=>{if(N(kt),Dt||Pt){const Wt=ih(Pt,Dt);X(kt,Wt),p.value[Wt]=Ot||kt.length}else b.value=Ot||kt.length},pt=async({productId:kt,blockId:Pt,isHidden:Dt})=>{if(!Y.value)return null;r.value[Pt]=!0;try{const Ot=await Bd(Y.value,{productId:kt,isHidden:Dt});return N(Ot.products),Ot.products[0]}catch(Ot){return o("notifications/notify",{message:`Error while getting store product: ${kt}.`}),jt(Ot),null}finally{r.value[Pt]=!1}},st=async({limit:kt,resetUndoForPageCreation:Pt=!0,pickStylesFromTheme:Dt=!1,shouldAwaitPageCreation:Ot=!1}={})=>{if(Y.value){r.value.global=!0;try{if(V.value){const Wt=await Bd(Y.value,{limit:kt||1});et({products:Wt.products,count:Wt.count}),o("addEcommerceProductPages",{pickStylesFromTheme:Dt,resetUndo:Pt})}else{const Wt=await Bd(Y.value);if(et({products:Wt.products,count:Wt.count}),!e["ecommerce/isStoreTypeZyro"])return;Ot?await o("addEcommerceProductPages",{pickStylesFromTheme:Dt,resetUndo:Pt}):o("addEcommerceProductPages",{pickStylesFromTheme:Dt,resetUndo:Pt})}}catch(Wt){o("notifications/notify",{message:"Error while getting store products."}),jt(Wt)}finally{r.value.global=!1}}},J=async({sortType:kt,collectionId:Pt,blockId:Dt,limit:Ot,offset:Wt})=>{r.value[Dt]=!0;try{const re=!kt&&Pt?"order=ASC&sort_by=collection_order":kt,pe=await Bd(Y.value,{sort:re,collectionId:Pt,limit:Ot,offset:Wt});et({products:pe.products,sort:re,collectionId:Pt,count:pe.count})}catch(re){o("notifications/notify",{message:"Error while getting store products."}),jt(re)}finally{r.value[Dt]=!1}},it=async()=>{try{const{products:kt}=await K9(Y.value),Pt=U.value.length?kt.map(Dt=>{const Ot=U.value.find(Wt=>Dt.id===Wt.id);return Ot?{...Dt,seo_settings:{...Ot.seo_settings}}:Dt}):kt;E.value=kt,T.value=Pt}catch(kt){o("notifications/notify",{message:"Error while getting store products seo data."}),jt(kt)}},at=kt=>{const Pt=T.value.map(Dt=>{const Ot=kt.find(Wt=>Wt.id===Dt.id);return Ot?ji(Dt,Ot):Dt});T.value=Pt},ot=kt=>{const Pt=E.value.map(Dt=>{const Ot=kt.find(Wt=>Wt.id===Dt.id);return Ot?ji(Dt,Ot):Dt});E.value=Pt},ft=async({shouldAwaitPageCreation:kt=!1,pickStylesFromTheme:Pt=!1,resetUndoForPageCreation:Dt=!0,limit:Ot}={})=>{const Wt=[st({pickStylesFromTheme:Pt,shouldAwaitPageCreation:kt,resetUndoForPageCreation:Dt,...Ot?{limit:Ot}:{}}),it()];await Promise.all(Wt)},tt=(kt,Pt)=>{const Dt=!kt&&Pt?"order=ASC&sort_by=collection_order":kt;return u.value[ih(Dt,Pt)]||[]},gt=(kt,Pt)=>{const Dt=!kt&&Pt?"order=ASC&sort_by=collection_order":kt;return p.value[ih(Dt,Pt)]||0},Q=kt=>{y.value=kt},bt=kt=>{let Pt=no.clone(kt);Object.entries(Pt.languages).forEach(([Wt,{blocks:re,elements:pe}])=>{const he=Object.keys(re).filter(Ce=>{var Ft;return $c.includes((Ft=re[Ce])==null?void 0:Ft.type)}),Oe=Object.keys(pe).filter(Ce=>{var Ft;return((Ft=pe[Ce])==null?void 0:Ft.type)==="GridEcommerceButton"});he.forEach(Ce=>{Pt=cy({siteData:Pt,blockId:Ce,locale:Wt})}),Oe.forEach(Ce=>{Pt=V3({siteData:Pt,elementId:Ce,locale:Wt})})}),delete Pt.meta[Zi];const{ecommerceShoppingCart:Dt,...Ot}=Pt;return Ot},wt=()=>{let kt=no.clone(n.site);o("unselectCurrentElement"),o("updateCurrentBlockId",null);const Pt=Object.keys(n.ecommerceLegacyProductPages);Pt.length&&Pt.forEach(Ot=>{kt=nl({siteData:kt,pageId:Ot,locale:F.value})});const Dt=bt(kt);o("overwriteWebsiteData",{websiteData:{...Dt}}),o("undoRedo/resetUndoRedo",null),s.saveWebsite()},yt=()=>{let kt=no.clone(n.site);o("unselectCurrentElement"),o("updateCurrentBlockId",null),o("updateCurrentPageId");const Pt=Object.keys(n.ecommerceDynamicProductPageTemplates);Pt.length&&Pt.forEach(Ot=>{kt=nl({siteData:kt,pageId:Ot,locale:F.value})});const Dt=bt(kt);o("overwriteWebsiteData",{websiteData:{...Dt}}),s.saveWebsite()},At=()=>{if(g.value=[],Object.keys(n.ecommerceDynamicProductPageTemplates).length){yt();return}wt()},mt=kt=>Object.values(n.ecommerceProductPages).some(({blocks:Pt})=>Pt==null?void 0:Pt.includes(kt)),Ct=()=>{g.value=[],u.value={},b.value=0,p.value={}},xt=({slug:kt})=>!W.value.includes(kt),Ht=()=>{const kt=Object.values(n.site.languages).reduce((pe,he)=>{const Oe=he.pages||{};return[...pe,...Object.values(Oe)]},[]),Pt=kt.map(pe=>pe==null?void 0:pe.slug).filter(Boolean),Dt=(pe,he)=>{const Oe=N3({initialSlug:pe.title,existingSlugs:[...he,...Pt],slugSuffix:"-product"}),{slug:Ce,...Ft}=pe.seo_settings||{};return{id:pe.id,seo_settings:{slug:Oe,title:pe.title,...Ft}}};if(V.value){const pe=T.value.map(Oe=>{var Ce;return(Ce=Oe.seo_settings)==null?void 0:Ce.slug}).filter(Boolean);return T.value.filter(Oe=>{var Ce;return!((Ce=Oe.seo_settings)!=null&&Ce.slug)}).map(Oe=>Dt(Oe,pe))}const Ot=[...g.value,...y.value],Wt=kt.filter(pe=>{var Ce;return pe.type===un?!(((Ce=Ot.find(Ft=>Ft.id===pe.productId))==null?void 0:Ce.seo_settings)||{}).slug:!1}),re=Ot.map(pe=>{var he;return(he=pe.seo_settings)==null?void 0:he.slug}).filter(Boolean);return Wt.map(pe=>{const he=Ot.find(({id:de})=>de===pe.productId);if(!he)return null;const Oe=new DOMParser().parseFromString(he.description,"text/html"),Ce=Oe?uy(Oe):"",Ft=Dt(he,re);return{...Ft,seo_settings:{...Ft.seo_settings,...he.thumbnail?{ogImagePath:he.thumbnail}:{},ogImageOrigin:"other",ogImageAlt:he.title,description:Ce}}}).filter(Boolean)},Gt=async()=>{const kt=Ht();if(kt!=null&&kt.length)try{const Pt=rf(kt,100).map(Wt=>g2(Y.value,Wt)),Dt=await Promise.all(Pt),Ot=Dt.flat().map(Wt=>({id:Wt.id,seo_settings:Wt.seo_settings}));V.value||o("ecommerce/updateStoreProducts",Dt.flat()),at(Ot),ot(Ot)}catch(Pt){throw o("notifications/notify",{messageI18nKeyPath:"builder.productPageDataSavingNotification",submitLabelI18nKeyPath:"common.reload",isDiscardButtonShown:!1,submitCallback:()=>window.location.reload()},{root:!0}),console.error(Pt),jt(Pt),Pt}},Lt=()=>{if(!Y.value)return;const kt=Object.entries(t.ecommerce.productMetaUpdates).map(([Pt,Dt])=>{const Ot=T.value.find(({id:re})=>re===Pt),Wt=(Ot==null?void 0:Ot.seo_settings)||{};return{id:Pt,seo_settings:{...Wt,...Dt||{}}}});kt.length&&(n.setEcommerceSeoChanges(kt),o("ecommerce/setProductMetaUpdates",null,{root:!0}),at(kt))},Tt=async()=>{Lt();const kt=Object.values(U.value);if(!kt.length)return;const Pt=rf(kt,100).map(Dt=>g2(Y.value,Dt));await Promise.all(Pt),E.value=E.value.map(Dt=>{const Ot=kt.find(re=>re.id===Dt.id),Wt=(Ot==null?void 0:Ot.seo_settings)||{};return{...Dt,seo_settings:{...Dt.seo_settings,...Wt}}}),n.resetEcommerceSeoChanges()},Vt=()=>{var Dt;if(e.isCurrentPageTypeDynamicProduct)return;const[kt]=Object.keys(n.ecommerceDynamicProductPageTemplates),{currentLocale:Pt}=t;Pt!==F.value&&o("updateCurrentLocale",F.value),o("updateCurrentPageId",kt),K(((Dt=T.value[0])==null?void 0:Dt.id)||-1)},ae=async()=>{var Pt,Dt;const{ecommerceStoreId:kt}=e.siteMeta;if(kt)try{const Wt=(await Promise.allSettled([Z9(kt),Q9(kt)])).map(he=>he.status==="fulfilled"?he.value:null),[re,pe]=Wt;a.value=!!((Pt=re==null?void 0:re.status)!=null&&Pt.paymentsEnabled),l.value=!!((Dt=re==null?void 0:re.status)!=null&&Dt.hasProducts),i.value=(pe==null?void 0:pe.store_payment_providers.some(he=>!pD.includes(he.status)))||!1}catch(Ot){o("notifications/notify",{message:`Error while getting store settings: ${kt}.`}),jt(Ot)}},ht=async()=>{var kt,Pt,Dt;if(Y.value)try{const Ot=await W9(Y.value),Wt=(kt=Ot.store_owner.language)==null?void 0:kt.toLowerCase();let re=await b2(Wt);if(P.value=Ot.stripe_public_key||"",z.value=Ot.stripe_account_id||"",re!=null&&re.onlineStore||(re=await b2("en")),o("addEcommerceShoppingCart",{translations:re==null?void 0:re.onlineStore,lang:Wt}),n.site.meta.payseraVerificationCode!==((Pt=Ot.paysera_checkout)==null?void 0:Pt.verification_code)){const{payseraVerificationCode:pe,...he}=n.site.meta;o("overwriteWebsiteData",{websiteData:{...n.site,meta:{...he,...(Dt=Ot.paysera_checkout)!=null&&Dt.verification_code?{payseraVerificationCode:Ot.paysera_checkout.verification_code}:{}}}}),o("undoRedo/resetUndoRedo")}}catch(Ot){o("notifications/notify",{message:"Error while getting settings."},{root:!0}),jt(Ot)}};return{isEditingGlobalPage:k,deleteEcommerceFromSite:At,currentDynamicPageProductId:I,setCurrentDynamicPageProductId:K,setCurrentDynamicPageProductIdBySlug:Z,getProductsSorted:tt,getCountSorted:gt,products:g,productSlugs:W,count:b,productsSorted:u,productsNonSorted:g,countSorted:p,hiddenProducts:y,allProducts:$,fetchProducts:st,fetchListProducts:J,isLoadingProducts:r,setStoreProducts:et,fetchProductById:pt,setHiddenProducts:Q,isDynamicPageFlowEnabled:V,getIsBlockInEcommerceProductPage:mt,resetProductsList:Ct,productsSeo:T,rawProductsSeo:E,fetchInitialEcommerceData:ft,getIsSlugNotUsedForProducts:xt,updateProductsSeoData:Lt,updateProductPagesWithoutSlugsSeo:Gt,fetchProductsSeo:it,updateStoreProductsSeo:at,productsSeoWithUpdates:M,saveEcommerceSeoChanges:Tt,initEcommerce:async({shouldPickStylesFromTheme:kt=!1,refetch:Pt=!1}={})=>{o("ecommerce/getVariantsQuantity"),await ft({pickStylesFromTheme:kt}),Pt||await Gt(),await Promise.all([ht(),o("ecommerce/getCategories"),ae()])},handleEditDynamicProductPageClick:Vt,getPaymentsSettings:ae,arePaymentsEnabled:a,hasAddedProducts:l,isPaymentsConnectionPending:i,getStoreSettingsData:ht,isStoreEnabled:L,isStoreUsed:D}}),hy=()=>(new URL(window.location.href).pathname.split("/")[1],!1),ps="builder",Js="preview",ta="ai-preview",xr="version-history",gD="store-manager-redirect",mD="site-settings",f2="form-email-verification",Rs="ai-builder",ms="templates",vo=()=>{const t=ni();return{isAiBuilderMode:c(()=>(t==null?void 0:t.name)===Rs)}},hD=12e4,fo=Wo(en.SAVING,()=>{const{state:t,dispatch:e}=nt(),o=ni(),n=Bt(),s=me(),{isAiBuilderMode:a}=vo(),l=C(!1),i=C(null),r=C(null),u=C(),p=c(()=>r.value?Md(r.value,n.site):void 0),g=c(()=>{const D=t.ecommerce.productMetaUpdates;return D&&Object.keys(D).length>0}),b=c(()=>g.value||typeof p.value<"u"),y=c(()=>(o==null?void 0:o.name)===xr||(o==null?void 0:o.name)===ta||a.value?!1:t.websiteId&&b.value&&!l.value),k=D=>{l.value=D},I=({siteData:D})=>{r.value=no.clone(D)},E=D=>{i.value=D},T=D=>{u.value=D},P=()=>{clearInterval(u.value)},z=async({saveWhenImpersonating:D=!1,isTimerStarted:$=!0}={})=>{var U;const{user:A,websiteId:M}=t;if(!((U=A.user)!=null&&U.isStaff&&!D||hy())){P(),k(!0),Se({category:"CLIENT_TIMESTAMP",message:"Before Save",data:{clientTimestamp:i.value}}),r9({websiteId:M,website:n.site});try{s.updateProductsSeoData();const Y=m9({siteData:n.site}),{data:F}=await a9(M,n.site,i.value,Y);Se({category:"CLIENT_TIMESTAMP",message:"After Save",data:{clientTimestamp:F.clientTimestamp}}),E(F.clientTimestamp),I({siteData:n.site})}catch(Y){throw e("notifications/notify",{messageI18nKeyPath:l9(Y),submitLabelI18nKeyPath:"common.reload",isDiscardButtonShown:!1,submitCallback:()=>window.location.reload()},{root:!0}),console.error(Y),Y}finally{$&&L(),k(!1)}}},L=()=>{var $,A;if(($=t.user.user)!=null&&$.isStaff||[V1.TEMPLATES,V1.AI_TEMPLATES].includes((A=t.user.user)==null?void 0:A.email))return;const D=setInterval(()=>{y.value&&z()},hD);T(D)};return{isSaving:l,clientTimestamp:i,siteDataSnapshot:r,timer:u,unsavedSiteDataDiff:p,hasUnsavedSeoChanges:g,hasUnsavedChanges:b,canSave:y,setIsSaving:k,setSiteDataSnapshot:I,setClientTimestamp:E,setTimer:T,clearTimer:P,saveWebsite:z,startSavingTimer:L}}),{HOME:bD,PAYMENTS:fD,SINGLE_SITE_DASHBOARD_SUBSCRIPTION:y2,SIGN_UP:yD,SIGN_IN:vD,SITES:J3,SUBSCRIPTIONS:_D}=xg,{PRODUCTS:wD,PRODUCTS_ADD:kD,PRODUCTS_EDIT:ID,PAYMENT_MANAGEMENT:SD,BOOKINGS:ED,SHIPPING_EDIT:xD,COMPANY_INFORMATION:TD}=lo,{LANG:CD,RETURN:lh,SITE_ID:_u,PLANS_TO_SHOW:v2,SUBSCRIPTION_ID:PD,PRODUCT:BD,FLOW:_2,ACTIVATE_PLAN:AD,REDIRECT_URL:wu}=No,{FLOW_UPGRADE:DD,FLOW_EXTEND:zD,RETURN_BUILDER:rh,PLANS_TO_SHOW_NON_ECOMMERCE:$D,PLANS_TO_SHOW_BUSINESS:LD}=On,{ASSIGN:w2}=xC,Mc=({path:t,params:e,domain:o})=>{const n=new URL(t,o);return n.search=new URLSearchParams(e).toString(),n.href},t8=({path:t="",params:e={}})=>Mc({path:t,params:e,domain:"https://zyro.com"}),k2=({path:t="",params:e={}})=>Mc({path:t,params:e,domain:"https://builder.hostinger.com"}),by=({path:t=J3,params:e={}}={})=>Mc({path:t,params:e,domain:"https://dashboard.zyro.com"}),Jp=({path:t="",params:e={}}={})=>Mc({path:t,params:{redirectUrl:window.location.href,...e},domain:"https://auth.hostinger.com/login"}),df=({path:t="",params:e={}}={})=>Mc({path:t,params:{redirectUrl:window.location.href,...e},domain:"https://hpanel.hostinger.com"}),sc=({path:t="",siteId:e="",params:o={}})=>{const n=[e,t].filter(l=>l).join("/"),s=new URL(n,"https://ecommerce.hostinger.com"),a={...o,[CD]:oy()};return Object.keys(a).forEach(l=>s.searchParams.append(l,a[l])),s.href},OD=({currentDomain:t,params:e={}})=>df({path:`${Ei.WEBSITES}/${t}/${Ei.UPGRADE}`,params:{redirectLocation:"list_view",isBuilderWebsite:1,...e}}),qo=()=>{const{state:t,getters:e,dispatch:o}=nt()??{},n=fo(),s=async()=>{!o||!n.canSave||await n.saveWebsite()},a=async({path:V=bD,params:K={},redirectType:Z=w2})=>{await s();const N=t8({path:V,params:K});window.location[Z](N)},l=async({path:V=J3,params:K={},redirectType:Z=w2}={})=>{await s();const N=by({path:V,params:K});window.location[Z](N)},i=async({path:V="",params:K={}}={})=>{await s(),await dn.redirectToHpanel({path:V,params:K})},r=async({currentDomain:V,siteId:K,params:Z={}})=>{await s(),dn.redirectToHpanel({path:`${Ei.ADD_DOMAIN}/${V}`,params:{[wu]:`https://builder.hostinger.com/${K}`,websiteType:"builder",...Z}})},u=async({currentDomain:V,siteId:K,params:Z={}})=>{await s(),dn.redirectToHpanel({path:`${Ei.DOMAIN}/${V}/${Ei.DOMAIN_OVERVIEW}`,params:{[wu]:`https://builder.hostinger.com/${K}`,...Z}})},p=async()=>{await s(),dn.redirectToHpanel({path:`${Ei.DOMAINS}`})},g=async({currentDomain:V,siteId:K,params:Z={}})=>{await s(),dn.redirectToHpanel({path:`${Ei.REGISTER_DOMAIN_RESOURCE}/${V}`,params:{[wu]:`https://builder.hostinger.com/${K}`,...Z}})},b=async({currentDomain:V,siteId:K,params:Z={}})=>{await s(),dn.redirectToHpanel({path:`${Ei.DOMAIN}/${V}/${Ei.DOMAIN_DNS}`,params:{[wu]:`https://builder.hostinger.com/${K}`,...Z}})},y=async({currentDomain:V,params:K={}})=>{await s(),dn.redirectToHpanel({path:`${Ei.WEBSITES}/${V}/${Ei.UPGRADE}`,params:{redirectLocation:"list_view",isBuilderWebsite:1,...K}})},k=()=>e["ecommerce/isStoreTypeZyro"]?LD:$D,I=(V={})=>{l({path:y2,params:{[_u]:t.websiteId,[_2]:DD,...V}})},E=(V={})=>{l({path:y2,params:{[_u]:t.websiteId,[_2]:zD,...V}})},T=V=>{const K=V[v2]||k(),Z={[_u]:t.websiteId,[v2]:K,[AD]:!0,...V};a({path:fD,params:Z})},P=({returnTo:V=rh}={})=>{a({path:yD,params:{[lh]:V}})},z=()=>{a({path:vD,params:{[lh]:rh}})},L=({websiteId:V,subscriptionId:K})=>{const Z={[lh]:rh};return V&&(Z[_u]=V),K&&(Z[PD]=K),l({path:_D,params:Z})},D=async({path:V="",params:K={},siteId:Z}={})=>{await s(),await dn.redirectToEcommerce({path:V,params:K,siteId:Z||(t==null?void 0:t.websiteId)})};return{redirectToWWW:a,redirectToUpgrade:I,redirectToExtend:E,redirectToDashboard:l,redirectToHPanel:i,redirectToWWWPayments:T,redirectToWWWSignUp:P,redirectToWWWSignIn:z,redirectToSubscriptions:L,redirectToEcommerce:D,redirectToEcommerceBookings:()=>{D({path:ED})},redirectToEcommerceProducts:()=>{D({path:wD})},redirectToEcommerceProductsAdd:()=>{D({path:kD})},redirectToEcommerceProductsEdit:V=>{D({path:ID,params:{[BD]:V}})},redirectToEcommercePayments:(V,K={})=>{D({path:SD,params:K,siteId:V})},redirectToEcommerceCompanyInformation:()=>{D({path:TD})},redirectToEcommerceShippingEdit:(V={})=>{D({path:xD,params:V})},redirectToHPanelAddDomain:r,redirectToHPanelDomainsPage:p,redirectToHPanelRegisterDomainResource:g,redirectToHPanelDomainSettings:u,redirectToHPanelDomainDNSSettings:b,redirectToHPanelUpgradePage:y,getRedirectLinkToUpgradePage:OD}},Gs=Wo("auth",()=>{const t=C(!1),e=C(!1),o=C([]),n=u=>{t.value=u},s=()=>{tf(10*1e3);const u=Jp();window.location.assign(u)},a=()=>new Promise(u=>{o.value.push(u)}),l=()=>{o.value.forEach(u=>u()),o.value=[]};return{getAuthToken:Ac,getBearerToken:s2,setAuthToken:Xp,checkIfTokenIsRefreshing:async()=>{e.value&&await a()},refreshToken:async u=>{const p=s2(),g=u&&p!==u;if(!(e.value||g||hy())){e.value=!0;try{const{data:b}=await s9();if(!b.token){s();return}Xp(b.token),l()}catch{s()}e.value=!1}},forceLogout:s,isAuthRedirecting:t,setIsAuthRedirecting:n}}),qn=Vd.create({timeout:15e4,headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":"application/json"}}}),RD=t=>(t.headers&&(t.headers[_r]=Fd(36)),t),MD=t=>{const e=Bt();return e.hResourceId&&(t.headers.hResourceId=e.hResourceId),t},HD=async t=>{if(t.isPublic)return t;const e=Gs();await e.checkIfTokenIsRefreshing();const o=e.getBearerToken();return e.getAuthToken()&&t.headers&&(t.headers.Authorization=o),t};qn.interceptors.request.use(HD);qn.interceptors.request.use(RD);qn.interceptors.request.use(MD);const ND=async t=>{const e={...t,isRetryNeeded:!1};await qn(e)},GD=t=>{const e=t||{},o=Gs(),n=e.headers.Authorization;return o.refreshToken(n),e._retry=!0,qn(t)};qn.interceptors.response.use(t=>t,async t=>{C3(t);const e=t==null?void 0:t.config,{serviceName:o}=E3(t==null?void 0:t.config),{message:n,status:s}=x3(t.response);return s===401&&(n==="jwt expired"||o!=="https://builder-backend.hostinger.com")&&!(e!=null&&e._retry)?GD(e):(e!=null&&e.isRetryNeeded&&await ND(e),P3(t),Promise.reject(t))});const Ut={get(t,e){return qn.get(t,e)},post(t,e,o){return qn.post(t,e,o)},put:(t,e,o)=>qn.put(t,e,o),patch:(t,e,o)=>qn.patch(t,e,o),delete:(t,e)=>qn.delete(t,e),request:t=>qn(t),isCancel:t=>Vd.isCancel(t),CancelToken:Vd.CancelToken,interceptors:qn.interceptors,defaults:qn.defaults},FD=(t,e)=>{const o=s=>{var a;return(a=s[1])==null?void 0:a.toUpperCase()};return t==null?void 0:t.toString().replace(/(_\w)/g,o)},Tr=t=>{if(Ip(t)&&!Array.isArray(t)){const e={};return Object.keys(t).forEach(o=>{e[FD(o)]=Tr(t[o])}),e}if(Array.isArray(t)){const e=[];return t.forEach(o=>e.push(Tr(o))),e}return t},VD="https://resources.hostinger.com/api",UD={getUserResources:async({types:t,states:e}={types:[],states:[]})=>{const{data:o}=await Ut.get(`${VD}/v2/resources`,{params:{...t&&{type:t},...e&&{state:e}}});return Tr(o.data)}},Le=()=>{const{dispatch:t,commit:e}=nt();return{notify:s=>t("notifications/notify",s),removeNotificationById:s=>e("notifications/removeToastById",s)}},Ea=Wo(en.RESOURCES,()=>{const{notify:t}=Le(),e=C(!1),o=C([]),n=C(null),s=p=>{n.value=p},a=async()=>{hy();try{o.value=await UD.getUserResources(),e.value=!0}catch(p){t({messageI18nKeyPath:"builder.siteResourcesFailedToLoad",theme:"error",submitCallback:()=>{}}),jt(p),e.value=!1}},l=p=>o.value.filter(g=>p.includes(g.type)),i=c(()=>o.value.filter(p=>p.type===ul.HOSTING&&p.state===Qp.PENDING)),r=c(()=>{var p;return(p=i.value.sort((g,b)=>g.createdAt>b.createdAt?-1:1))==null?void 0:p[0]}),u=c(()=>o.value.find(p=>String(p.id)===n.value));return{fetchResources:a,getResourcesByTypes:l,setSiteHResourceId:s,siteHResourceId:n,pendingHostingResources:i,mostRecentPendingResource:r,siteResource:u,resources:o,isLoaded:e}}),jD=({site:t,currentPageId:e,currentBlockId:o,currentElementId:n})=>{const{state:s}=nt(),a=Ea(),l=c(()=>{var St;return((St=t.value)==null?void 0:St.meta)||{}}),i=c(()=>s.currentLocale),r=c(()=>a.siteHResourceId),u=c(()=>l.value.template),p=c(()=>u.value===N5),g=c(()=>u.value===G5),b=c(()=>u.value==="blank"),y=c(()=>p.value||g.value||b.value?u.value:"template"),k=c(()=>{var St;return((St=l.value)==null?void 0:St.defaultLocale)||Kt}),I=c(()=>{var St;return((St=t.value)==null?void 0:St.languages)||{}}),E=c(()=>Object.entries(I.value).filter(([St])=>St!==Kt).map(([St,xe])=>({...xe,locale:St}))??[]),T=c(()=>E.value.length>0),P=c(()=>{var St;return((St=I.value)==null?void 0:St[i.value])||{}}),z=c(()=>{var St,xe;return((xe=(St=I.value)==null?void 0:St[k.value])==null?void 0:xe.pages)||{}}),L=c(()=>{var St;return((St=t.value)==null?void 0:St.styles)||{}}),D=c(()=>{var St;return((St=L.value)==null?void 0:St.font)||{}}),$=c(()=>{var St;return((St=t.value)==null?void 0:St.forms)||{}}),A=c(()=>Object.values(I.value[Kt].pages).find(({type:St})=>St===ll)),M=c(()=>go(z.value,({value:St})=>[un,Uo].includes(St.type))),U=c(()=>i.value===Kt?P.value.pages||{}:{[qi]:{...A.value},...P.value.pages,...M.value}),Y=c(()=>P.value.blocks||{}),F=c(()=>P.value.elements||{}),W=c(()=>Y.value.header),V=c(()=>Object.values(Y.value).find(St=>St.slot==="footer")),K=c(()=>!!V.value),Z=St=>Object.keys(U.value).includes(St),N=c(()=>U.value[e.value]),X=c(()=>{var St;return((St=N.value)==null?void 0:St.type)===Mn}),et=c(()=>{var St;return((St=N.value)==null?void 0:St.type)===Uo}),pt=c(()=>{var St;return((St=N.value)==null?void 0:St.type)===ll}),st=c(()=>{var St;return oi((St=N.value)==null?void 0:St.type)}),J=c(()=>Y.value[o.value]),it=c(()=>{var St;return(St=J.value)==null?void 0:St.type}),at=c(()=>{var St;return(St=J.value)==null?void 0:St.settings}),ot=c(()=>{var St;return(St=at.value)==null?void 0:St.styles}),ft=c(()=>{var St;return(St=J.value)==null?void 0:St.slot}),tt=c(()=>F.value[n.value]),gt=c(()=>{const St=tt.value;return St&&"content"in St?St.content:null}),Q=c(()=>{var St;return(St=tt.value)==null?void 0:St.settings}),bt=c(()=>{var St;return(St=Q.value)==null?void 0:St.styles}),wt=c(()=>{var St;return(St=tt.value)==null?void 0:St.type}),yt=c(()=>Vg({elementId:n.value,siteBlocks:Y.value})||""),At=c(()=>Y.value[yt.value]||""),mt=c(()=>{var St;return(St=At.value)==null?void 0:St.type}),Ct=c(()=>{var St,xe;return N.value&&((xe=(St=N.value)==null?void 0:St.blocks)==null?void 0:xe.length)===0}),xt=({slug:St,slugPageId:xe})=>!Object.entries(U.value).some(([qe,Zt])=>qe!==xe&&Zt.slug===St),Ht=St=>Object.keys(Y.value).find(xe=>{var qe;return(qe=Y.value[xe].components)==null?void 0:qe.includes(St)}),Gt=c(()=>P.value.nav||[]),Lt=c(()=>P.value.isNavHidden||!1),Tt=c(()=>P.value.blogReadingTimeText||""),Vt=c(()=>P.value.homePageId),ae=c(()=>U.value[Vt.value]),ht=c(()=>{var St,xe;return((xe=(St=ae.value)==null?void 0:St.meta)==null?void 0:xe.title)||ae.value.name}),$t=c(()=>go(z.value,({value:St})=>St.type===un)),kt=c(()=>go(z.value,({value:St})=>St.type===Uo)),Pt=c(()=>!!Object.keys($t.value).length),Dt=c(()=>{var St;return(St=t.value)==null?void 0:St.ecommerceShoppingCart}),Ot=c(()=>{var St;return((St=t==null?void 0:t.value)==null?void 0:St.blogCategories)||{}}),Wt=c(()=>{var St,xe;return(xe=(St=W.value)==null?void 0:St.settings)==null?void 0:xe.isLanguageSwitcherHidden}),re=c(()=>go(U.value,({value:St})=>St.type===Dr)),pe=c(()=>go(U.value,({value:St})=>St.type===Mn)),he=c(()=>go(pe.value,({value:St})=>St.isDraft&&!St.isScheduled)),Oe=c(()=>go(pe.value,({value:St})=>St.isScheduled)),Ce=c(()=>go(pe.value,({value:St})=>!St.isDraft&&!St.isScheduled)),Ft=c(()=>{var St;return(St=t.value)==null?void 0:St.ecommerceSeoChanges}),de=c(()=>{var St;return(St=t.value)==null?void 0:St.builderCompletedSteps}),Pe=c(()=>{var St;return(St=l.value)==null?void 0:St.isPrivateModeActive});return{currentLocale:i,site:t,siteLanguages:I,siteLanguagesList:E,hasLanguages:T,currentSiteLanguage:P,siteBlocks:Y,siteElements:F,sitePages:U,siteNav:Gt,isNavHidden:Lt,blogReadingTimeText:Tt,hResourceId:r,homePageId:Vt,ecommerceProductPages:M,ecommerceLegacyProductPages:$t,ecommerceDynamicProductPageTemplates:kt,defaultLocale:k,ecommerceShoppingCart:Dt,siteForms:$,siteStyles:L,siteTemplate:u,hasGeneratedTemplate:p,hasImportedTemplate:g,hasBlankTemplate:b,templateType:y,siteHomePageTitle:ht,siteFonts:D,currentPage:N,currentBlock:J,currentBlockType:it,currentBlockSettings:at,currentBlockStyles:ot,currentBlockSlot:ft,currentElement:tt,currentElementContent:gt,currentElementSettings:Q,currentElementStyles:bt,currentElementType:wt,currentElementBlockId:yt,currentElementBlock:At,currentElementBlockType:mt,getElementBLockId:Ht,headerBlock:W,footerBlock:V,doesFooterExist:K,doesPageIdAlreadyExist:Z,isCurrentPageTypeBlog:X,isCurrentPageTypeDynamicProduct:et,isCurrentPageEmpty:Ct,isCurrentPagePrivate:pt,isCurrentPageTypeEcommerceProduct:st,isPageSlugUnique:xt,blogCategories:Ot,isLanguageSwitcherHidden:Wt,defaultPages:re,blogPages:pe,draftBlogPages:he,scheduledBlogPages:Oe,publishedBlogPages:Ce,builderCompletedSteps:de,siteMeta:l,isPrivateModeActive:Pe,ecommerceSeoChanges:Ft,isLegacyProductPagesAdded:Pt}},cf=(t,e,o)=>o.indexOf(t)===e,e8=({type:t,tagName:e,properties:o={},children:n=[]})=>{if(t!=="element")return console.error("Failed to injected HTML element - missing node type");const s=document.createElement(e);if(Object.entries(o).forEach(([a,l])=>{s.setAttribute(a,l)}),n.length){const a=n.find(l=>l.type==="text").value;a&&(s.innerHTML=a)}return s},o8=t=>{const e=`[${Xi}="${t}"]`;return document.querySelector(e)},gl=t=>{const e=e8(t),o=o8(e.getAttribute(Xi));return e.outerHTML===(o==null?void 0:o.outerHTML)?o:(o==null||o.remove(),document.head.append(e),e)},WD=t=>{const e=e8(t),o=o8(e.getAttribute(Xi));return e.outerHTML===(o==null?void 0:o.outerHTML)?o:(o==null||o.remove(),document.body.append(e),e)},qg=({languages:t})=>Object.values(t).flatMap(e=>Object.values(e.elements)),qD=({languages:t})=>Object.values(t).flatMap(e=>{var o;return((o=e.blocks[To])==null?void 0:o.items)??[]}),n8=t=>{if(!t.toSorted)return t;const{withPositions:e,reorderedLanguages:o}=t.reduce((n,s)=>(Number.isInteger(s.orderPosition)&&s.orderPosition>=0?n.withPositions.push(s):n.reorderedLanguages.push(s),n),{withPositions:[],reorderedLanguages:[]});return e.toSorted((n,s)=>n.orderPosition-s.orderPosition).forEach(n=>{o.splice(n.orderPosition,0,n)}),o},YD=[Hn,_g,es],KD={normal:400,bold:700},ZD=["100","100italic","200italic","200","300italic","300","regular","italic","400","400italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],QD="custom",uf="google",ac=t=>KD[t]||Number(t),yi=t=>t.split(",")[0].replace(/["']+/g,""),XD=(t,e)=>t?`'${t}', ${e}`:null,JD=t=>`var(--${Ic}-${t})`,pf=t=>t.trim().replace(/ /g,"+"),fy=t=>{const e=new RegExp(`var\\(--${Ic}-|\\)`,"g");return t.replace(e,"")},dh=t=>{const e={regular:400,italic:"400italic"};return t.filter(o=>ZD.includes(o)).map(o=>{const n=Number(o)||o;return e[o]||n})},i8=t=>{let e={primary:[400],secondary:[400]};return l4.forEach(o=>{const n=fy(t[o][Ig]),s=ac(t[o][dr]);e={...e,[n]:[...e[n],s]}}),{[xn]:e[xn].filter(cf).sort(),[bi]:e[bi].filter(cf).sort()}},yy=t=>({[xn]:yi(t[xn]),[bi]:yi(t[bi])}),tz=(t,e)=>Object.keys(t).map(o=>({name:pf(t[o]),weights:e[o].join(";")})).filter(({weights:o})=>!!o).map(o=>`family=${o.name}:wght@${o.weights}`).join("&"),Cr=({googleFonts:t,customFonts:e,fontFamily:o,fontWeight:n})=>{if(!t.length||!o)return null;const s=n.toString(),a=e.find(r=>r.family.trim()===o.trim());if(a)return a.weights=[s],a;const l=s==="400"?"regular":s;return t.some(r=>r.family===o&&r.variants.includes(l))?{family:o,type:uf,weights:[s]}:null},ez=({html:t,customFonts:e,googleFonts:o})=>(t.match(/style\s*=\s*"([^"]*)"/gm)||[]).reduce((a,l)=>{var p,g;const i=(p=l.match(/font-family:.(.*?)[",;]/m))==null?void 0:p[1],r=((g=l.match(/font-weight:.(.*?)[";]/m))==null?void 0:g[1])||"400";if(!i)return a;const u=Cr({googleFonts:o,customFonts:e,fontFamily:i.replaceAll("\\",""),fontWeight:r});return[...a,u]},[]).filter(a=>a),oz=({languages:t,googleFonts:e,customFonts:o})=>qg({languages:t}).filter(({type:s,fontFamily:a})=>YD.includes(s)&&a).map(({fontFamily:s,fontWeight:a})=>Cr({googleFonts:e,customFonts:o,fontFamily:s,fontWeight:a})),nz=({languages:t,googleFonts:e,customFonts:o})=>qg({languages:t}).filter(({type:s,submitButtonFontFamily:a,formFontFamily:l})=>s===js&&(a||l)).flatMap(({submitButtonFontFamily:s,submitButtonFontWeight:a,formFontFamily:l,formFontWeight:i})=>[...s?[Cr({googleFonts:e,customFonts:o,fontFamily:s,fontWeight:a})]:[],...l?[Cr({googleFonts:e,customFonts:o,fontFamily:l,fontWeight:i})]:[]]),iz=({languages:t,googleFonts:e,customFonts:o})=>qg({languages:t}).filter(({type:s})=>s===_l).map(({fontFamily:s})=>Cr({googleFonts:e,customFonts:o,fontFamily:s,fontWeight:400})),sz=({languages:t,googleFonts:e,customFonts:o})=>Object.entries(t).map(([,n])=>{const{fontFamily:s,fontWeight:a}=n.blocks.header;return Cr({googleFonts:e,customFonts:o,fontFamily:s,fontWeight:a})}),s8=({siteData:t,html:e,customFonts:o,googleFonts:n})=>{const{styles:s}=t,a=yy(s.font),l=i8(s),i=[{family:a.primary,weights:l.primary,type:uf},{family:a.secondary,weights:l.secondary,type:uf}],r=ez({html:e,customFonts:o,googleFonts:n}),u=oz({languages:t.languages,googleFonts:n,customFonts:o}),p=nz({languages:t.languages,googleFonts:n,customFonts:o}),g=iz({languages:t.languages,googleFonts:n,customFonts:o}),b=sz({languages:t.languages,googleFonts:n,customFonts:o});return[...i,...r,...u,...p,...g,...b].filter(I=>I).reduce((I,E)=>{const T=I.findIndex(({family:P})=>P.trim()===E.family.trim());return T!==-1?(I[T].weights=[...new Set([...I[T].weights,...E.weights])],I):[...I,E]},[])},az=({customFonts:t,siteId:e})=>`
${t.map(({family:o,fileType:n})=>`
@font-face {
font-family: ${decodeURI(o).trim()};
src: url('https://assets.zyrosite.com/${e}/${o}.${n}') format('${n}');
font-display: swap;
}
`).join("")}`,lz=({customFonts:t,siteId:e})=>{const o=az({customFonts:t,siteId:e}),n={type:"element",tagName:"style",properties:{[Xi]:"custom-fonts"},children:[{type:"text",value:o}]};gl(n)},I2=["latin"],S2="'Roboto',sans-serif",Bt=Wo(en.SITE,()=>{var la;const{dispatch:t}=nt(),e=fo(),o=ee=>{console.log(ee),t("notifications/notify",{message:"Unexpected error occurred. Try reloading the page."})},n=C({}),s=C(null),a=C({}),l=C(""),i=C(""),r=C(""),u=C(""),{currentLocale:p,siteLanguages:g,siteLanguagesList:b,hasLanguages:y,currentSiteLanguage:k,siteBlocks:I,siteElements:E,sitePages:T,siteNav:P,isNavHidden:z,blogReadingTimeText:L,homePageId:D,hResourceId:$,ecommerceProductPages:A,ecommerceDynamicProductPageTemplates:M,ecommerceLegacyProductPages:U,defaultLocale:Y,ecommerceShoppingCart:F,siteForms:W,siteStyles:V,siteTemplate:K,hasBlankTemplate:Z,hasGeneratedTemplate:N,hasImportedTemplate:X,templateType:et,siteHomePageTitle:pt,siteFonts:st,currentPage:J,currentBlock:it,currentBlockType:at,currentBlockSettings:ot,currentBlockStyles:ft,currentBlockSlot:tt,currentElement:gt,currentElementContent:Q,currentElementSettings:bt,currentElementStyles:wt,currentElementType:yt,currentElementBlockId:At,currentElementBlock:mt,currentElementBlockType:Ct,getElementBLockId:xt,headerBlock:Ht,footerBlock:Gt,doesFooterExist:Lt,doesPageIdAlreadyExist:Tt,isCurrentPageTypeBlog:Vt,isCurrentPageEmpty:ae,blogCategories:ht,isLanguageSwitcherHidden:$t,defaultPages:kt,blogPages:Pt,draftBlogPages:Dt,scheduledBlogPages:Ot,publishedBlogPages:Wt,builderCompletedSteps:re,siteMeta:pe,isPrivateModeActive:he,isCurrentPagePrivate:Oe,isCurrentPageTypeEcommerceProduct:Ce,ecommerceSeoChanges:Ft,isLegacyProductPagesAdded:de}=jD({site:n,currentPageId:i,currentBlockId:r,currentElementId:u}),Pe=c(()=>pe.value.isCustomCodeDisabled||!1),St=ee=>{n.value.meta.isCustomCodeDisabled=ee},xe=ee=>{l.value=ee},qe=ee=>{i.value=ee},Zt=ee=>{r.value=ee},ro=ee=>{u.value=ee},Eo=({locale:ee=Kt,id:fe})=>{n.value.languages[ee].homePageId=fe},$o=({locale:ee=p.value,value:fe})=>{n.value.languages[ee].metaHtmlLanguage=fe},sn=ee=>{s.value=ee},ns=ee=>{try{n.value=ee}catch(fe){o(fe)}},Al=ee=>{try{n.value.languages=ee}catch(fe){o(fe)}},Xr=({locale:ee=Kt,data:fe})=>{try{n.value.languages[ee]=fe}catch(Ne){o(Ne)}},Ts=({locale:ee=Kt,pageId:fe,data:Ne})=>{try{n.value.languages[ee].pages={...n.value.languages[ee].pages,[fe]:Ne}}catch(uo){o(uo)}},Dl=({locale:ee=Kt,blockId:fe,data:Ne})=>{try{n.value.languages[ee].blocks[fe]=Ne}catch(uo){o(uo)}},aa=ee=>{try{a.value=ee}catch(fe){o(fe)}},zl=({locale:ee=Kt,elementId:fe,data:Ne})=>{try{n.value.languages[ee].elements={...n.value.languages[ee].elements,[fe]:Ne}}catch(uo){o(uo)}},_e=({locale:ee=Kt,data:fe})=>{try{const Ne=Oe.value?Kt:ee;n.value.languages[Ne].elements={...n.value.languages[Ne].elements,...fe}}catch(Ne){o(Ne)}},Ye=({key:ee,value:fe})=>{try{const Ne={...n.value.meta,[ee]:fe};n.value.meta=Ne}catch(Ne){o(Ne)}},Vi=ee=>{try{n.value.fonts=ee}catch(fe){o(fe)}},Be=({element:ee,value:fe})=>{try{const Ne={...n.value.styles,[ee]:{...n.value.styles[ee],...fe}};n.value.styles=Ne}catch(Ne){o(Ne)}},Zo=({element:ee,property:fe,value:Ne})=>{try{const uo={...n.value.styles,[ee]:{...n.value.styles[ee],[fe]:Ne}};n.value.styles=uo}catch(uo){o(uo)}},Bn=ee=>{try{n.value.builderCompletedSteps=ee}catch(fe){o(fe)}},Jr=({pageId:ee,nonExistingBlocks:fe})=>{const Ne=n.value.languages[p.value].pages[ee];Ne.blocks=[...(Ne.blocks||[]).filter(uo=>!fe.includes(uo))]},Tm=({slug:ee,pageId:fe})=>!Object.entries(T.value).filter(([uo])=>!(uo===fe||uo===D.value)).filter(([,{type:uo}])=>![$i.PAGE_TYPE_ECOMMERCE_DYNAMIC_PRODUCT,$i.PAGE_TYPE_PRIVATE,$i.PAGE_TYPE_ECOMMERCE_PRODUCT].includes(uo)).map(([,uo])=>uo.slug).includes(ee),Cs=ee=>{try{const Ne=(n.value.ecommerceSeoChanges||[]).filter(uo=>!ee.some(is=>uo.id===is.id));n.value.ecommerceSeoChanges=[...Ne,...ee]}catch(fe){o(fe)}},lu=()=>{n.value.ecommerceSeoChanges=[]};Rt(()=>{var ee;return(ee=n.value.styles)==null?void 0:ee.font},async(ee,fe)=>{const Ne=fe==null?void 0:fe[xn],uo=fe==null?void 0:fe[bi],is=ee==null?void 0:ee[xn],ra=ee==null?void 0:ee[bi],du=is!==Ne,td=ra!==uo;if((td||du)&&(is||ra)){const ed=I2.includes(yi(is)),Ui=I2.includes(yi(ra));if(ed||Ui){Se({category:"MALFORMED_FONT_SET",message:"Malformed primary or secondary font has been used",data:{isPrimaryFontMalformed:ed,isSecondaryFontMalformed:Ui,didSecondaryFontChange:td,didPrimaryFontChange:du,initialPrimaryFont:Ne,newPrimaryFont:is,initialSecondaryFont:uo,newSecondaryFont:ra},level:"debug",type:"debug"}),jt(new Error("Malformed font has been set"));const da={primary:ed?S2:is,secondary:Ui?S2:ra};da.primary&&da.secondary&&(Be({element:Ic,value:da}),e.canSave&&await e.saveWebsite({saveWhenImpersonating:!0}))}}},{immediate:!0});const ru=!!((la=Cx())!=null&&la._testing);return{websiteId:l,site:ru?n:c(()=>s.value||n.value),siteBackup:s,siteMeta:pe,isPrivateModeActive:he,currentBlockId:r,currentElementId:u,currentPageId:i,addElementData:a,currentLocale:p,siteLanguages:g,siteLanguagesList:b,hasLanguages:y,currentSiteLanguage:k,siteBlocks:I,siteElements:E,sitePages:T,siteNav:P,isNavHidden:z,blogReadingTimeText:L,homePageId:D,hResourceId:$,ecommerceProductPages:A,ecommerceDynamicProductPageTemplates:M,ecommerceLegacyProductPages:U,defaultLocale:Y,ecommerceShoppingCart:F,siteForms:W,siteStyles:V,siteTemplate:K,hasGeneratedTemplate:N,hasImportedTemplate:X,hasBlankTemplate:Z,templateType:et,siteHomePageTitle:pt,siteFonts:st,currentPage:J,currentBlock:it,currentBlockType:at,currentBlockSettings:ot,currentBlockStyles:ft,currentBlockSlot:tt,currentElement:gt,currentElementContent:Q,currentElementSettings:bt,currentElementStyles:wt,currentElementType:yt,currentElementBlockId:At,currentElementBlock:mt,currentElementBlockType:Ct,getElementBLockId:xt,headerBlock:Ht,footerBlock:Gt,doesFooterExist:Lt,doesPageIdAlreadyExist:Tt,isCurrentPageTypeBlog:Vt,isCurrentPageTypeEcommerceProduct:Ce,isCurrentPageEmpty:ae,getIsPageSlugUnique:Tm,blogCategories:ht,isLanguageSwitcherHidden:$t,defaultPages:kt,blogPages:Pt,draftBlogPages:Dt,scheduledBlogPages:Ot,publishedBlogPages:Wt,builderCompletedSteps:re,ecommerceSeoChanges:Ft,setSiteId:xe,setSiteCurrentElementId:ro,setSiteCurrentPageId:qe,setSiteCurrentBlockId:Zt,setSiteData:ns,setSitePageData:Ts,setSiteBlockData:Dl,setSiteElementData:zl,setSiteElementsData:_e,setSiteLanguagesData:Al,setSiteHomePageId:Eo,setMetaHtmlLanguage:$o,setSiteBuilderCompletedStepsData:Bn,setSiteMetaData:Ye,setSiteFontsData:Vi,setSiteAddElementData:aa,setSiteStyleProperties:Be,setSiteStyleProperty:Zo,removeNonExistingBlocksFromSite:Jr,setSiteLanguageData:Xr,isCustomCodeDisabled:Pe,setSiteCustomCodeDisabled:St,setEcommerceSeoChanges:Cs,resetEcommerceSeoChanges:lu,isLegacyProductPagesAdded:de,setSiteBackupData:sn}}),rz=()=>{const{state:t}=nt();return{isMobileScreen:c(()=>t.gui.isMobileScreen)}},Yg=Wo(en.GUI,()=>{const{isMobileScreen:t}=rz(),e=C(!1);return{isMobileScreen:t,isProductPageTemplateNotificationShown:e,setIsProductPageTemplateNotificationShown:n=>{e.value=n}}}),vy=({languages:t,defaultLocale:e})=>Object.keys(t).filter(o=>o!==Kt).map(o=>{const{isHidden:n,flagPath:s,country:a,name:l,orderPosition:i}=t[o];return{isHidden:n,flagPath:s,country:a,name:l,href:e===o?"/":`/${o}`,locale:o,orderPosition:i}})??[],dz=t=>Object.keys(t).length===0,cz=(t,e,o=!0,n=!1)=>Object.fromEntries(Object.entries(t).map(([s,a])=>{if(!a.isScheduled)return[s,a];const{date:l}=a,u=new Date(l).setHours(0,0,0,0)<=e||o;return[s,{...a,...u?{isDraft:!1}:{isDraft:!0}}]}).filter(s=>!s[1].isDraft||s[1].isDraft&&n).filter(s=>!dz(s[1]))),Hc=({path:t,languageKeys:e=[],defaultLocale:o="system"})=>{const[n,s]=t.split("/").filter(a=>a!=="");return!e||!e.length>1?{locale:o,slug:n}:e.includes(n)?{locale:n,slug:s}:{locale:o??Kt,slug:n}},uz=({siteData:t,path:e})=>{if(!t)return null;const{meta:o,languages:n}=t,{locale:s}=Hc({path:e,languageKeys:Object.keys(n),defaultLocale:o.defaultLocale}),{homePageId:a}=n[s];return a},pz=({siteData:t,path:e})=>{if(!t)return!1;const{meta:o,languages:n}=t,{locale:s,slug:a}=Hc({path:e,languageKeys:Object.keys(n),defaultLocale:o.defaultLocale}),{pages:l,homePageId:i}=n[s];return!a||l[i].slug===a},a8=({siteData:t,path:e,products:o=[],isDynamicProductPageEnabled:n=!1})=>{var p,g;if(!t)return null;const{meta:s,languages:a}=t,{locale:l,slug:i}=Hc({path:e,languageKeys:Object.keys(a),defaultLocale:s.defaultLocale}),{pages:r,homePageId:u}=a[l];if(i){const b=(p=o==null?void 0:o.find(k=>{var I;return((I=k.seo_settings)==null?void 0:I.slug)===i}))==null?void 0:p.id;return b&&n?(g=Object.entries(r).find(([I,{type:E}])=>E===Uo))==null?void 0:g[0]:Object.keys(r).find(k=>b?r[k].productId===b:r[k].slug===i)||u}return u},gz=[zr,Lr],mz=({siteBlocks:t,pageBlocksIds:e})=>Object.fromEntries(Object.entries(t).filter(([o,{type:n,slot:s}])=>{const a=e.includes(o),l=gz.includes(n);return a||l||s===yg})),hz=({siteBlocks:t,pageBlocksIds:e})=>Object.entries(t).find(([n,s])=>e.includes(n)&&s.type===$r)?Object.fromEntries(Object.entries(t).filter(([,{type:n}])=>n===yl)):{},bz=({siteElements:t,blocks:e,isCustomCodeDisabled:o})=>{const n=Object.values(e).map(({components:a})=>a).flatMap(a=>a),s=a=>o&&a.type==="GridEmbed"?{...a,content:""}:a;return Object.fromEntries(Object.entries(t).map(([a,l])=>[a,s(l)]).filter(([a])=>n.includes(a)))},E2=({page:t,isPreviewMode:e})=>{var o;return t?!((o=t==null?void 0:t.meta)!=null&&o.password)||e?t:{...t,meta:{...t.meta,password:!0},blocks:[]}:null},l8=({siteData:t,locale:e,pageId:o,isAstro:n,isPreviewMode:s,isCustomCodeDisabled:a,buildDate:l})=>{var D;const{defaultLocale:i=Kt}=t.meta,r=Object.fromEntries(Object.entries(t.languages[i].pages).filter(([,{type:$}])=>$===un)),u=Object.entries(r).map(([$])=>$),p=t.languages[e],{blocks:g,elements:b}=t.languages[i],y=E2({page:p.pages[o],isPreviewMode:s});if(!y)return null;const I=Object.values(p.blocks).filter($=>($==null?void 0:$.type)===Go.BLOCK_LAYOUT).some($=>$.slot===yg)?Object.entries(g).filter(([$,A])=>A.type!=="footer"):g,E=mz({siteBlocks:{...I,...p.blocks},pageBlocksIds:[...(y==null?void 0:y.blocks)||[],...u]}),T=hz({siteBlocks:{...I,...p.blocks},pageBlocksIds:[...(y==null?void 0:y.blocks)||[],...u]}),P=bz({siteElements:{...b,...p.elements},blocks:{...E,...T},isCustomCodeDisabled:a}),z=cz(p.pages,new Date().setHours(0,0,0,0),n,s);return{pages:{...Object.fromEntries(Object.entries(z).map(([$,A])=>[$,E2({page:A,isPreviewMode:s})])),...r},blocks:{...E,...T},elements:P,nav:p.nav,currentLocale:e,homePageId:p.homePageId,isNavHidden:p.isNavHidden,cookieBannerAcceptText:p.cookieBannerAcceptText,cookieBannerDisclaimer:p.cookieBannerDisclaimer,cookieBannerDeclineText:p.cookieBannerDeclineText,blogReadingTimeText:p.blogReadingTimeText,metaTitle:p.metaTitle,meta:t.meta,forms:t.forms,styles:t.styles,domain:t.domain??t.freeDomain,siteId:t.siteId,ecommerceShoppingCart:t.ecommerceShoppingCart,blogCategories:t.blogCategories,languageSwitcherLanguages:vy({languages:t.languages,defaultLocale:t.meta.defaultLocale}),currentPageId:o,productId:y.productId,languageKeys:Object.keys(t.languages),isDynamicProductPageEnabled:Bc({defaultLocalePages:(D=t==null?void 0:t.languages[i])==null?void 0:D.pages}),buildDate:l}},fz=({pageId:t,website:e,path:o,defaultLocale:n})=>{var l;const s=Bc({defaultLocalePages:(l=e==null?void 0:e.languages[n])==null?void 0:l.pages});return uz({siteData:e,path:o})===t&&!pz({siteData:e,path:o})&&s},yz=({website:t,defaultLocale:e})=>{const o=Object.keys(t.languages[e].pages).find(n=>{const s=t==null?void 0:t.languages[e].pages[n];return(s==null?void 0:s.type)===Uo});return l8({siteData:t,locale:e,pageId:o,isAstro:!1,isPreviewMode:!1,isCustomCodeDisabled:t.meta.isCustomCodeDisabled||!1})},vz=t=>t.startsWith("www."),_y=t=>vz(t)?t.substring(4):t,_z=t=>{const e=_y(t),[o,...n]=e.split(".");return{domainName:o,tld:n.join(".")}},gf=()=>{const t=window.location.hostname.split(".");return t.slice(Math.max(t.length-2,1)).join(".")},Nn="gui",wz="UPDATE_IS_MOBILE_SCREEN",r8="UPDATE_HEADER_HEIGHT",De="OPEN_MODAL",Te="CLOSE_MODAL",x2="OPEN_SIDEBAR",tg="CLOSE_SIDEBAR",kz="TOGGLE_SIDEBAR",Kn="OPEN_DRAWER",hs="CLOSE_DRAWER",xa="TOGGLE_DRAWER",T2="OPEN_HEATMAP",Ql="CLOSE_HEATMAP",d8="TOGGLE_HEATMAP",Gr="CHANGE_DRAWER_PAGE",c8="CHANGE_DRAWER_OPTIONS",u8="CHANGE_PREVIOUS_DRAWER_PAGE",C2="SET_IS_MOBILE_SCREEN",ch="SET_ACTIVE_MODAL",uh="SET_SIDEBAR_OPEN",ph="SET_ACTIVE_DRAWER",gh="SET_HEATMAP_OPEN",P2="SET_HEADER_HEIGHT",ku="SET_DRAWER_PAGE",mf="SET_BLOCK_RESIZE_INFO",B2="SET_COLOR_PICKER_OPEN",{mapState:p8}=Br(Nn),{mapActions:on}=Br(Nn);Br(Nn);const A2=({previewSiteData:t,defaultLocale:e,locale:o,previewPageId:n,path:s})=>(s?fz({pageId:n,website:t,path:s,defaultLocale:e}):!1)?yz({website:t,defaultLocale:e}):l8({siteData:t,locale:o,pageId:n,isAstro:!1,isPreviewMode:!0}),Iz={namespaced:!0,state:{isMobileView:!1,isMobileScreen:window.innerWidtht.isMobileScreen||t.isMobileView,isColorPickerOpen:t=>t.isColorPickerOpen,isSetupPaymentProviderNotificationVisible:t=>t.isSetupPaymentProviderNotificationVisible,isAddFirstProductNotificationVisible:t=>t.isAddFirstProductNotificationVisible,isBottomEcommerceNotificationVisible:(t,e)=>e.isSetupPaymentProviderNotificationVisible||e.isAddFirstProductNotificationVisible},mutations:{toggleMobileView:t=>{t.isMobileView=!t.isMobileView},toggleDesktopView:t=>{t.isMobileView=!1},toggleSiteBeingPublished:t=>{t.isSiteBeingPublished=!t.isSiteBeingPublished},setIsSiteBeingUpdated:(t,e)=>{t.isSiteBeingUpdated=e},setBuilderPreviewContainerRef:(t,{builderPreviewContainerRef:e})=>{t.builderPreviewContainerRef=e},setIsAssetManagerVisible:(t,e)=>{t.isAssetManagerVisible=e},[P2]:(t,e)=>{t.headerHeight=e},[ch]:(t,{name:e,settings:o})=>{Yo("activeModal",e??"none"),t.activeModalName=e,t.activeModalSettings=o},[uh]:(t,e)=>{t.isSidebarOpen=e},[gh]:(t,e)=>{t.isHeatmapOpen=e},[ph]:(t,{id:e,settings:o})=>{Yo("activeDrawer",e??"none"),t.activeDrawer=e,t.activeDrawerSettings=o},[C2]:(t,e)=>{t.isMobileScreen=e},[ku]:(t,{drawerPage:e,drawerKey:o})=>{t.drawerPage[o]=e},[mf]:(t,e)=>{t.blockResizeInfo=e},[B2]:(t,e)=>{t.isColorPickerOpen=e},setPreviewSiteData:(t,e)=>{t.previewSiteData=e},setPreviewPageData:(t,e)=>{t.previewPageData=e},setIsP2PBannerShown:(t,e)=>{t.isP2PBannerShown=e},setActiveDrawerSettings:(t,e)=>{t.activeDrawerSettings=e},setIsSetupPaymentProviderNotificationVisible:(t,e)=>{t.isSetupPaymentProviderNotificationVisible=e},setIsAddFirstProductNotificationVisible:(t,e)=>{t.isAddFirstProductNotificationVisible=e},setCurrentPreviewProductPageId:(t,e)=>{t.currentPreviewProductPageId=e}},actions:{setAssetManagerVisibility({commit:t},e){t("setIsAssetManagerVisible",e)},setBuilderPreviewContainerRef({commit:t},{builderPreviewContainerRef:e}){t("setBuilderPreviewContainerRef",{builderPreviewContainerRef:e})},setIsSiteBeingUpdated({commit:t},e){t("setIsSiteBeingUpdated",e)},toggleMobileView:async({dispatch:t,commit:e})=>{await t("leaveElementEditMode",{saveToHistory:!1},{root:!0}),e("toggleMobileView")},[r8]:({state:t,commit:e},o)=>{!t.headerHeight&&o&&e(P2,o)},[Gr]:({commit:t},{drawerKey:e,pageKey:o,options:n={}})=>{const s=Wb[e][o],a={...s,options:{...s.options,...n}};t(ku,{drawerKey:e,drawerPage:a})},[c8]:({commit:t,state:e},{drawerKey:o,options:n={}})=>{const s=e.drawerPage[o],a={...s,options:{...s.options,...n}};t(ku,{drawerKey:o,drawerPage:a})},[u8]:({commit:t,state:e},o)=>{const n=e.drawerPage[o].previousPage??v0,s=to(Wb[o][n]);t(ku,{drawerPage:s,drawerKey:o})},[x2]:({commit:t})=>t(uh,!0),[De]:({commit:t},{name:e,settings:o={}})=>{t(ch,{name:e,settings:o})},[Te]:({commit:t})=>{t(ch,{name:null,settings:{}})},[tg]:({commit:t,dispatch:e})=>{t(uh,!1),e(Ql)},[kz]:({state:t,dispatch:e})=>{e(t.isSidebarOpen?tg:x2)},[T2]:({state:t,commit:e,dispatch:o})=>{o(hs),t.isHeatmapOpen||e(gh,!0)},[Ql]:({state:t,commit:e})=>{t.isHeatmapOpen&&e(gh,!1)},[d8]:({state:t,dispatch:e})=>{e(t.isHeatmapOpen?Ql:T2)},[Kn]:({rootState:t,commit:e,dispatch:o},{id:n,settings:s})=>{var a;n===Ks&&(a=t.user)!=null&&a.id&&window.hj("identify",t.user.id,{"builder.blog.open_sidebar":!0}),o(Ql),e(ph,{id:n,settings:s})},[hs]:({commit:t})=>t(ph,{id:null,settings:null}),[xa]:({state:t,dispatch:e},o)=>{const n={[gs]:"website_builder.add_element.enter",[Yi]:"website_builder.pages_and_navigation.enter",[io]:"website_builder.global_styles.enter",[Ks]:"website_builder.blog.enter",[Ag]:"website_builder.languages.enter"};n[o]&&t.activeDrawer!==o&&Et.logEvent({eventName:n[o]}),e(t.activeDrawer===o?hs:Kn,{id:o})},[wz]:({commit:t},e)=>t(C2,e),updateBlockResizeInfo:({commit:t},e)=>{t(mf,e)},updateIsColorPickerOpen:({commit:t},e)=>t(B2,e),setPreviewSiteData:({commit:t},e)=>t("setPreviewSiteData",e),setPreviewPageData:({commit:t},e)=>t("setPreviewPageData",e),updatePreviewSiteData:({rootState:t,dispatch:e},o)=>{if(o){const{currentLocale:n,currentPageId:s}=t,a=o.meta.defaultLocale||Kt,l=s===qi||!Object.keys(o.languages).includes(n)?Kt:n,i=A2({previewSiteData:o,locale:l,defaultLocale:a,previewPageId:s});e("setPreviewSiteData",o),e("setPreviewPageData",i)}},updatePreviewPageData:({state:t,rootState:e,dispatch:o,commit:n},{path:s})=>{var a;if(t.previewSiteData){const{currentPageId:l}=e,i=me(),r=l===qi,u=((a=t.previewSiteData)==null?void 0:a.meta.defaultLocale)??Kt,p=r?qi:a8({path:s,siteData:t.previewSiteData,products:i.productsSeo}),{locale:g}=r?{locale:Kt}:Hc({path:s,defaultLocale:u,languageKeys:Object.keys(t.previewSiteData.languages)}),b=A2({previewSiteData:t.previewSiteData,locale:g,defaultLocale:u,previewPageId:p,path:s}),y=s.split("/")[1],{id:k}=[...i.rawProductsSeo,...i.productsSeo].find(I=>{var E;return((E=I.seo_settings)==null?void 0:E.slug)===y})||{};n("setCurrentPreviewProductPageId",k),o("setPreviewPageData",b)}},setCurrentPreviewProductPageId:({commit:t},e)=>t("setCurrentPreviewProductPageId",e),setIsP2PBannerShown:({commit:t},e)=>t("setIsP2PBannerShown",e),setActiveDrawerSettings:({commit:t},e)=>t("setActiveDrawerSettings",e),setIsSetupPaymentProviderNotificationVisible:({commit:t,rootGetters:e},o)=>{t("setIsSetupPaymentProviderNotificationVisible",o),o?Et.logEvent({eventName:"website_builder.ecomm_payment_modal.shown",eventProperties:{builder:!0}}):Mi(j3(e.siteMeta.ecommerceStoreId),Date.now().toString(),1,{cdomain:gf()})},setIsAddFirstProductNotificationVisible:({commit:t,rootGetters:e},o)=>{t("setIsAddFirstProductNotificationVisible",o),o?Et.logEvent({eventName:"website_builder.ecomm_products_banner.shown",eventProperties:{builder:!0}}):Mi(W3(e.siteMeta.ecommerceStoreId),Date.now().toString(),1,{cdomain:gf()})}}},mh=C(!1),hh=C(null),ad=C(1),Fr=()=>{const{dispatch:t}=nt(),e=Bt(),o=Yg(),n=me(),s=C(c1.length),a=c(()=>{var g;return((g=e.siteMeta)==null?void 0:g.isExistingStoreWithDynamicTemplate)&&!Do(u1)}),l=c(()=>ad.value===s.value),i=({stepIndex:g})=>{ad.value=g,hh.value=c1[g-1],hh.value===Tg&&(t(`gui/${Kn}`,{id:null}),n.handleEditDynamicProductPageClick())},r=()=>{t(`gui/${Te}`),mh.value=!1,Mi(u1,1,365)};return{currentProductTemplateOnboardingStep:hh,isProductTemplateOnboardingModalVisible:a,isOnboardingVisible:mh,isLastStep:l,productTemplateOnboardingStepCount:s,currentProductTemplateStepIndex:ad,startProductTemplateOnboarding:()=>{if(o.isMobileScreen){n.handleEditDynamicProductPageClick(),r();return}t(`gui/${Te}`),o.setIsProductPageTemplateNotificationShown(!1),py(e.websiteId),t(`gui/${Kn}`,{id:kr}),mh.value=!0,i({stepIndex:1})},finishProductTemplateOnboarding:r,goToNextProductTemplateOnboardingStep:()=>{if(ad.value===s.value){r();return}i({stepIndex:ad.value+1})},setProductTemplateOnboardingStep:i}},Sz={class:"template-onboarding-popup__header"},Ez={class:"text-bold-2"},xz={class:"template-onboarding-popup__content"},Tz={class:"text-body-2"},Cz={class:"template-onboarding-popup__footer"},Pz={class:"template-onboarding-popup__step-count text-body-2"},Bz=q({__name:"BuilderProductPageTemplateOnboardingStep",props:{left:{default:"45%"},top:{default:"80%"},placement:{},usePopupOffset:{type:Boolean,default:!0},offset:{}},setup(t){ue(g=>({"172d2831":g.top,"6317d6aa":g.left}));const{t:e}=_t(),{currentProductTemplateOnboardingStep:o,productTemplateOnboardingStepCount:n,currentProductTemplateStepIndex:s,finishProductTemplateOnboarding:a,goToNextProductTemplateOnboardingStep:l,isLastStep:i}=Fr(),r=C(null),u=C(null),p=c(()=>o.value&&PC[o.value]);return Nt(()=>{r.value&&r.value.scrollIntoView({behavior:"smooth"})}),(g,b)=>{const y=ct("qa");return d(),v("div",{ref_key:"pulsingDotRef",ref:r,class:rt(["template-onboarding",{"template-onboarding--with-popup-offset":g.usePopupOffset}])},[h(ty),p.value?(d(),S(ve,{key:0,"target-ref":r.value,placement:g.placement,offset:g.offset,flip:!1,"auto-update":"",onClickOutside:f(a)},{default:_(()=>[m("div",{ref_key:"pulsingDotPopupRef",ref:u,class:"template-onboarding-popup"},[m("div",Sz,[m("p",Ez,w(f(e)(p.value.title18nPath)),1),O((d(),S(ut,{"button-type":"plain",size:"sm",title:g.$t("common.close"),class:"template-onboarding-popup__button",onClick:f(a)},{icon:_(()=>[h(lt,{name:"close"})]),_:1},8,["title","onClick"])),[[y,"modal-btn-close"]])]),m("div",xz,[m("p",Tz,w(f(e)(p.value.description18nPath)),1)]),m("div",Cz,[m("p",Pz,w(`${f(s)}/${f(n)}`),1),O((d(),S(ut,{title:f(e)("builder.onboarding.next"),onClick:f(l)},{default:_(()=>[j(w(f(i)?f(e)("common.done"):f(e)("builder.onboarding.next")),1)]),_:1},8,["title","onClick"])),[[y,"template-onboarding-next"]])])],512)]),_:1},8,["target-ref","placement","offset","onClickOutside"])):B("",!0)],2)}}}),wy=H(Bz,[["__scopeId","data-v-0c0ad9a6"]]),Az={class:"add-block-button"},Dz={class:"add-block-button__onboarding"},zz=q({__name:"AddBlockButton",props:{blockId:{},isProductTemplateOnboardingStepAddSectionVisible:{type:Boolean}},setup(t){const e=t,{getters:o,dispatch:n}=nt(),{t:s}=_t(),a=C(null),l=c(()=>o["gui/isMobileMode"]),i=()=>{n("unselectCurrentElement"),n(`gui/${De}`,{name:r0,settings:{previousBlockId:e.blockId}}),a.value&&a.value.blur(),Et.logEvent({eventName:"website_builder.add_section.enter"})};return(r,u)=>{const p=ct("qa");return d(),v("div",Az,[m("div",Dz,[O((d(),S(ut,{ref:"addSectionButton",class:rt(["add-block-button__button",{"add-block-button__button--mobile":l.value}]),"aria-label":r.$t("common.addSection"),theme:"add-block",onClick:i},{"icon-left":_(()=>[h(lt,{name:"add"})]),default:_(()=>[j(" "+w(l.value?null:f(s)("common.addSection")),1)]),_:1},8,["class","aria-label"])),[[p,"builder-btn-addsection"]]),r.isProductTemplateOnboardingStepAddSectionVisible?(d(),S(wy,{key:0,left:"50%",top:"0%",placement:"top",offset:{mainAxis:-240,crossAxis:0}})):B("",!0)])])}}}),g8=H(zz,[["__scopeId","data-v-d4c1c896"]]),$z=5,Lz=q({__name:"ResizeHandle",props:{type:{type:String,default:"default"},resizeDirection:{type:Number,default:0}},setup(t){const e=t,o=c(()=>e.type==="error"),n=c(()=>e.resizeDirection*$z);return(s,a)=>(d(),v("button",{ref:"resizeButton",class:rt(["resize-handle",`resize-handle--${t.type}`]),style:ne(`--resize-movement-length: ${n.value}px`)},[h(qt,{name:"chevron",direction:"up",class:rt(["resize-handle__icon",{"resize-handle__icon--disabled":o.value}])},null,8,["class"]),h(qt,{name:"chevron",direction:"down"})],6))}}),Oz=H(Lz,[["__scopeId","data-v-749feecd"]]),Rz=()=>{const t=C(null),e=C(null),o=n=>{t.value=n.clientX,e.value=n.clientY};return document.addEventListener("mousemove",o),mn(()=>{document.removeEventListener("mousemove",o)}),{mouseX:t,mouseY:e}},D2=C(null),z2=C(null),Kg=()=>{const t=e=>{const o=e.touches[0];D2.value=o.clientX,z2.value=o.clientY};return document.addEventListener("touchmove",t),mn(()=>{document.removeEventListener("touchmove",t)}),{touchX:D2,touchY:z2,handleTouchEvent:t}},$2=C(!1),L2=C(0),m8=()=>({initializeScrollHandler:e=>{$2.value||(e.addEventListener("scroll",()=>{L2.value=e.scrollTop}),$2.value=!0)},scrollYAmount:L2}),Ad="ontouchstart"in window,Iu=C(null),ky=({trackScroll:t=!0}={})=>{const{mouseX:e,mouseY:o}=Rz(),{touchX:n,touchY:s}=Kg(),{scrollYAmount:a}=m8(),{state:l}=nt(),i=c(()=>l.gui.builderPreviewContainerRef),r=C(null),u=C(null),p=C(0),g=C(!1),b=C(!1),y=c(()=>Ad?n.value:e.value),k=c(()=>Ad?s.value:o.value),I=c(()=>Ad?"touchmove":"mousemove"),E=c(()=>Ad?"touchend":"mouseup"),T=({onDragEnd:M=null}={})=>{g.value=!0,r.value=y.value,u.value=k.value,p.value=a.value,document.addEventListener(E.value,()=>{M==null||M(),r.value=null,u.value=null,b.value=!1,g.value=!1},{once:!0}),document.addEventListener(I.value,()=>{g.value&&(b.value=!0)},{once:!0})},P=c(()=>t&&b.value?a.value-p.value:0),z=c(()=>b.value?y.value-r.value:0),L=c(()=>b.value?k.value-u.value+P.value:0),D=c(()=>{const M=k.value>document.documentElement.clientHeight-P1,U=k.value-u.value>0;return M&&U&&g.value}),$=c(()=>{const M=k.value{i.value.scrollBy(0,M)};return Rt([D,$],()=>{t&&((D.value||$.value)&&!Iu.value?Iu.value=setInterval(()=>{A(D.value?B1:-B1)},pB):(clearInterval(Iu.value),Iu.value=null))}),{startDragging:T,dragDeltaXPosition:z,dragDeltaYPosition:L,isDragging:g,hasMouseMoved:b}},bh=C(null),Fs=C(null),Wi=C(null),Zg=(t,e)=>{const{getters:o,dispatch:n}=nt(),s=c(()=>o.siteElements),a=c(()=>o["gui/isMobileMode"]),l=c(()=>a.value?se:ge),{startDragging:i,dragDeltaYPosition:r,isDragging:u}=ky(),p=C(null),g=c(()=>o.siteBlocks[t.blockId]),b=c(()=>{var M;const A=(M=g.value)==null?void 0:M.components;return!A||!A.length?null:A.map(U=>{const{desktop:Y,mobile:F}=s.value[U];return{bottom:a.value&&F?F.top+F.height:Y.top+Y.height,elementId:U}}).sort((U,Y)=>Y.bottom-U.bottom)[0]}),y=c(()=>{var A;return((A=b.value)==null?void 0:A.bottom)||0}),k=c(()=>{var A;if(a.value){const M=Yp>y.value?Yp:y.value;return((A=g.value.mobile)==null?void 0:A.minHeight)||M}return g.value.desktop.minHeight}),I=C(null),E=c(()=>u.value?Math.max(Gb,k.value+r.value,y.value):null),T=c(()=>E.value===y.value+eB||E.value===Gb),P=c(()=>u.value&&T.value?"error":"default"),z=({minHeight:A,saveToHistory:M})=>{A&&(n("updateBlockData",{blockId:t.blockId,blockData:{[l.value]:{minHeight:Math.max(y.value,A)}},merge:!0}),M&&n("undoRedo/createSnapshot"))},L=()=>{z({minHeight:E.value,saveToHistory:!0}),e.emit("lock-hovered-block",!1),e.emit("set-edit-control-visibility",!0),Fs.value=null,Wi.value=null},D=()=>{I.value=k.value,i({onDragEnd:L}),Wi.value=t.blockId,e.emit("set-edit-control-visibility",!1),e.emit("lock-hovered-block",!0),n("updateCurrentBlockId",t.blockId)},$=()=>{y.value>=k.value&&z({minHeight:y.value,saveToHistory:!1})};return Rt(E,(A,M)=>{Fs.value=E.value,p.value=u.value?Math.sign(A-M):0}),Rt(T,()=>{T.value&&b.value?bh.value=b.value.elementId:bh.value=null}),{blockingElementId:bh,startSectionResizing:D,resizeHandleType:P,resizeHandleDirection:p,saveBlockMinHeight:z,blockMinHeight:k,updateSectionMinHeight:$,lowestElementBottom:y}},Mz=q({components:{ResizeHandle:Oz},props:{blockId:{type:String,required:!0}},setup(t,e){const{startSectionResizing:o,resizeHandleType:n,resizeHandleDirection:s}=Zg(t,e),{handleTouchEvent:a}=Kg();return{startSectionResizingOnTouchStart:i=>{a(i),o()},startSectionResizing:o,resizeHandleType:n,resizeHandleDirection:s,handleTouchEvent:a}}});function Hz(t,e,o,n,s,a){const l=G("ResizeHandle");return d(),S(l,{type:t.resizeHandleType,"resize-direction":t.resizeHandleDirection,onMousedown:Yt(t.startSectionResizing,["left","stop"]),onTouchstart:Yt(t.startSectionResizingOnTouchStart,["prevent"])},null,8,["type","resize-direction","onMousedown","onTouchstart"])}const Nz=H(Mz,[["render",Hz]]),O2=C(!1),fh=C(null),kl=()=>{const{getters:t}=nt(),e=c(()=>t.siteBlocks),o=c(()=>{var s;return(s=fh.value)==null?void 0:s.id});return{hoveredBlock:fh,hoveredBlockId:o,isHoveredBlockLocked:O2,handleBlockHover:({blockId:s})=>{O2.value||(fh.value={id:s,type:e.value[s].type,slot:e.value[s].slot})}}},Gz={class:"block-controls__selection"},Fz={class:"block-controls__resize-handle-container"},Vz={class:"block-controls__resize-handle-text text-body-2"},Uz={__name:"BlockControls",props:{blockId:{type:String,required:!0},targetRef:{type:HTMLElement,default:null},isFirstBlock:{type:Boolean,default:!1},isLastBlock:{type:Boolean,default:!1},isResizeHandleVisible:{type:Boolean,default:!1},isAddBlockButtonVisible:{type:Boolean,default:!0},sectionTitle:{type:String,default:""},blockSelectInfoColor:{type:String,default:"var(--color-azure-dark)"},transparentHeaderHeight:{type:Number,default:0},isPillDisabled:{type:Boolean,default:!1}},emits:["unhide-block","set-edit-control-visibility"],setup(t){ue(U=>({c256535e:D.value}));const e=t,{getters:o,state:n}=nt(),s=Bt(),{t:a}=_t(),{isHoveredBlockLocked:l,hoveredBlock:i}=kl(),{isOnboardingVisible:r,currentProductTemplateOnboardingStep:u}=Fr(),p=C(null),g=c(()=>o["gui/isMobileMode"]),b=c(()=>n.gui.isMobileScreen),y=c(()=>n.currentBlockId),k=c(()=>s.siteBlocks[e.blockId]),I=c(()=>k.value&&k.value.type===yl),E=c(()=>I.value&&r.value&&u.value===Tg),T=c(()=>y.value===e.blockId),P=c(()=>{var U;return((U=i.value)==null?void 0:U.id)===e.blockId}),z=c(()=>b.value||e.isAddBlockButtonVisible),L=c(()=>e.isResizeHandleVisible&&P.value),D=c(()=>`${e.transparentHeaderHeight}px`),$=c(()=>({y1:0,y2:0,x1:0,x2:0,title:e.sectionTitle||a("common.section"),color:e.blockSelectInfoColor})),A=()=>{var U;return Number.parseInt((U=e.targetRef)==null?void 0:U.clientHeight,10)||0},M=U=>{l.value=U};return(U,Y)=>{const F=ct("qa");return d(),v("div",{ref_key:"blockControlsRef",ref:p,class:rt(["block-controls",{"block-controls--hovered":P.value||E.value,"block-controls--is-selected":T.value,"block-controls--is-last":t.isLastBlock}])},[z.value?O((d(),S(g8,{key:0,"is-product-template-onboarding-step-add-section-visible":E.value,class:"block-controls__add-block","block-id":t.blockId},null,8,["is-product-template-onboarding-step-add-section-visible","block-id"])),[[F,"block-controls-add-block"]]):B("",!0),O((d(),v("div",Gz,[h(E7,{"use-border":"","disable-pill-overflow":t.isFirstBlock,"is-pill-disabled":t.isPillDisabled,info:$.value,"block-id":t.blockId,"is-block-selected":T.value,"is-block-hovered":P.value},null,8,["disable-pill-overflow","is-pill-disabled","info","block-id","is-block-selected","is-block-hovered"])])),[[F,"block-selection-overlay"]]),m("div",Fz,[h(Mo,{position:"top","toggle-event":"hover","hide-tooltip":g.value,"use-portal":!1,"content-position":"absolute","forced-position":{right:"-35px",bottom:"30px","white-space":"nowrap"}},{trigger:_(()=>[L.value?(d(),S(Nz,{key:0,class:"block-controls__resize-handle","block-id":t.blockId,"block-height":A(),onLockHoveredBlock:M,onSetEditControlVisibility:Y[0]||(Y[0]=W=>U.$emit("set-edit-control-visibility",W))},null,8,["block-id","block-height"])):B("",!0)]),default:_(()=>[m("p",Vz,w(U.$t("builder.sectionControlLine.text")),1)]),_:1},8,["hide-tooltip"])])],2)}}},Da=H(Uz,[["__scopeId","data-v-9517f41d"]]),ce={Backspace:"Backspace",ShiftLeft:"ShiftLeft",Escape:"Escape",Space:"Space",ArrowLeft:"ArrowLeft",ArrowUp:"ArrowUp",ArrowRight:"ArrowRight",ArrowDown:"ArrowDown",Delete:"Delete",KeyX:"KeyX",KeyC:"KeyC",KeyD:"KeyD",KeyY:"KeyY",KeyZ:"KeyZ",OSLeft:"OSLeft",NumLockSlash:"NumLockSlash",KeySlash:"Slash",Enter:"Enter",BracketLeft:"BracketLeft",BracketRight:"BracketRight"},jz={8:ce.Backspace,16:ce.ShiftLeft,27:ce.Escape,32:ce.Space,37:ce.ArrowLeft,38:ce.ArrowUp,39:ce.ArrowRight,40:ce.ArrowDown,46:ce.Delete,67:ce.KeyC,68:ce.KeyD,88:ce.KeyX,89:ce.KeyY,90:ce.KeyZ,91:ce.OSLeft,111:ce.NumLockSlash,191:ce.KeySlash,219:ce.BracketLeft,221:ce.BracketRight},He=t=>{let e;return t?t.code!==void 0?e=t.code==="MetaLeft"?"OSLeft":t.code:t.keyCode!==void 0&&(e=jz[t.keyCode]):e=void 0,e},Wz=q({props:{inputId:{type:String,default:null},modelValue:{type:String,required:!0},placeholder:{type:String,default:""},disabled:{type:Boolean,default:!1},type:{type:String,default:""},maxlength:{type:[String,Number],default:null},color:{type:String,default:"",validator(t){return["","light"].includes(t)}},error:{type:[String,Boolean],default:""},padding:{type:String,default:""},theme:{type:String,default:"primary",validator:t=>["primary","secondary","hostinger"].includes(t)},minValue:{type:Number,default:null},autofocus:{type:Boolean,default:!1},suffix:{type:String,default:null},focusOnMount:{type:Boolean,default:!1},isSpinnerDisabled:{type:Boolean,default:!0},inputType:{type:String,default:"",validator:t=>["","number"].includes(t)},qaSelector:{type:String,default:""}},emits:["update:model-value","input-blur","input-focus","keyup-enter"],data(){return{inputTextCanvas:null,suffixPosition:null,shiftKeyPressed:!1,metaKeyPressed:!1}},computed:{computedStyles(){return{"--z-padding":this.padding||void 0,"--suffix-left":this.suffixPosition||void 0}},getInputStyles(){const t=window.getComputedStyle(this.$refs.inputRef,null).getPropertyValue("font-size"),e=window.getComputedStyle(this.$refs.inputRef,null).getPropertyValue("font-family");return`${t} ${e}`}},watch:{modelValue:{handler(){this.suffix&&this.updateSuffixPosition()}}},mounted(){this.suffix&&(this.inputTextCanvas=document.createElement("canvas"),this.getTextWidth(this.modelValue),this.updateSuffixPosition()),this.focusOnMount&&this.$refs.inputRef.focus()},methods:{getTextWidth(t){const e=this.inputTextCanvas.getContext("2d"),o=e.measureText(t);return e.font=this.getInputStyles,o.width},updateSuffixPosition(){this.suffixPosition=`${this.getTextWidth(this.modelValue)+20}px`},replaceNonNumberCharacters(t){return t.replace(/[^\d.-]/g,"")},handleInputControls(t){const e=[ce.ShiftLeft,ce.OSLeft,ce.ArrowUp,ce.ArrowDown];if(this.inputType!=="number"||!e.includes(He(t)))return;t.preventDefault(),He(t)===ce.ShiftLeft&&(this.shiftKeyPressed=!0),He(t)===ce.OSLeft&&(this.metaKeyPressed=!0);let o=Number(this.modelValue);!this.shiftKeyPressed&&!this.metaKeyPressed&&He(t)===ce.ArrowUp&&(o+=1),!this.shiftKeyPressed&&!this.metaKeyPressed&&He(t)===ce.ArrowDown&&(o-=1),He(t)===ce.ArrowUp&&this.shiftKeyPressed&&(o+=10),He(t)===ce.ArrowDown&&this.shiftKeyPressed&&(o-=10),He(t)===ce.ArrowUp&&this.metaKeyPressed&&(o+=100),He(t)===ce.ArrowDown&&this.metaKeyPressed&&(o-=100),this.$emit("update:model-value",o)},resetPressedKeyModifiers(t){He(t)===ce.ShiftLeft&&(this.shiftKeyPressed=!1),He(t)===ce.OSLeft&&(this.metaKeyPressed=!1)},handleInputChange(t){let{value:e}=t.target;(this.type==="number"||this.inputType==="number")&&(e=this.replaceNonNumberCharacters(e),Number(e[0])===0&&e[1]!=="."&&e.length>1&&(e=e.slice(1))),this.maxlength&&this.type==="number"&&(e=e.slice(0,Math.max(0,Number(this.maxlength)))),this.$emit("update:model-value",e)}}}),qz=["id","value","disabled","placeholder","type","maxlength","autofocus","min"];function Yz(t,e,o,n,s,a){const l=ct("qa");return d(),v("div",{class:rt(["zyro-input",[{[`zyro-input--${t.theme}`]:t.theme},{"text-body-2":t.theme==="primary"},{"text-body-1":t.theme==="secondary"},{"zyro-input--light":t.color},{"zyro-input--error":t.error},{"zyro-input--spinner-disabled":t.isSpinnerDisabled}]]),style:ne(t.computedStyles)},[O(m("input",{id:t.inputId||void 0,ref:"inputRef",class:"zyro-input__input",value:t.modelValue,disabled:t.disabled,autocomplete:"off",placeholder:t.placeholder,type:t.type,maxlength:t.maxlength,autofocus:t.autofocus,min:t.minValue,onKeydown:e[0]||(e[0]=(...i)=>t.handleInputControls&&t.handleInputControls(...i)),onKeyup:[e[1]||(e[1]=(...i)=>t.resetPressedKeyModifiers&&t.resetPressedKeyModifiers(...i)),e[5]||(e[5]=Bi(i=>t.$emit("keyup-enter"),["enter"]))],onInput:e[2]||(e[2]=(...i)=>t.handleInputChange&&t.handleInputChange(...i)),onBlur:e[3]||(e[3]=i=>t.$emit("input-blur",i)),onFocus:e[4]||(e[4]=i=>t.$emit("input-focus",i))},null,40,qz),[[l,t.qaSelector]]),t.suffix?(d(),v("span",{key:0,ref:"inputSuffix",class:"zyro-input__suffix"},w(t.suffix),513)):B("",!0)],6)}const bs=H(Wz,[["render",Yz],["__scopeId","data-v-6d61e03e"]]),Nc=t=>(ke("data-v-c95fc470"),t=t(),Ie(),t),Kz={class:"ai-type-dropdown"},Zz={key:0,class:"ai-type-dropdown__content text-body-3"},Qz={class:"ai-type-dropdown__types"},Xz={key:0,class:"ai-type-dropdown__types-item ai-type-dropdown__types-item"},Jz=Nc(()=>m("p",null,"Custom",-1)),t$=["onMouseover"],e$=["onClick"],o$=["onClick"],n$=["onClick"],i$={class:"ai-type-dropdown__types"},s$=Nc(()=>m("p",null,"Default",-1)),a$=["onMouseover"],l$=["onClick"],r$={key:1,class:"ai-type-tooltip text-body-3"},d$=Nc(()=>m("span",null,"Name",-1)),c$=["disabled"],u$=Nc(()=>m("span",null,"Description",-1)),p$=Nc(()=>m("span",{class:"dialog-content__form-note"},"description will be used by AI service to generate relevant content",-1)),g$={class:"dialog-content__form-buttons"},m$=q({__name:"AiTypeDropdown",props:{customOptions:{},defaultOptions:{},selectedOption:{},hasAiType:{type:Boolean}},emits:["select-option","add-new-type","edit-type","delete-type"],setup(t,{emit:e}){const o=e,n=t,s=C(null),a=C(""),l=C(""),i=C(!1),r=C(null),u=C(!1),p=c(()=>r.value?{...n.defaultOptions,...n.customOptions}[r.value]:""),g=()=>{i.value=!i.value},b=()=>{s.value&&s.value.showModal()},y=()=>{s.value&&(a.value="",l.value="",u.value=!1,s.value.close())},k=()=>{if(!(!a.value||!l.value)){if(u.value){o("edit-type",{name:a.value,description:l.value}),y();return}o("add-new-type",{name:a.value,description:l.value}),y()}},I=E=>{s.value&&(u.value=!0,l.value=n.customOptions[E],a.value=E,s.value.showModal())};return(E,T)=>(d(),v(dt,null,[m("div",Kz,[m("button",{class:"ai-type-dropdown__button",onClick:g},[m("span",null,w(n.selectedOption||"Select type"),1),h(lt,{name:"chevron_right",dimensions:"16px",direction:i.value?"left":"right"},null,8,["direction"])]),i.value?(d(),v("div",Zz,[m("div",Qz,[E.hasAiType?(d(),v("div",Xz,[m("button",{onClick:T[0]||(T[0]=P=>o("select-option",""))}," None ")])):B("",!0),Jz,m("ul",null,[m("li",{class:"ai-type-dropdown__types-item ai-type-dropdown__types-item--outline"},[m("button",{onClick:b}," Add custom type ")]),(d(!0),v(dt,null,zt(n.customOptions,(P,z)=>(d(),v("li",{key:z,class:"ai-type-dropdown__types-item",onMouseover:L=>r.value=z,onMouseleave:T[1]||(T[1]=L=>r.value=null)},[m("button",{onClick:L=>E.$emit("select-option",z)},w(z),9,e$),m("button",{class:"ai-type-dropdown__action-button",onClick:L=>I(z)},[h(lt,{name:"edit",dimensions:"16px"})],8,o$),m("button",{class:"ai-type-dropdown__action-button ai-type-dropdown__action-button--danger",onClick:L=>E.$emit("delete-type",z)},[h(lt,{name:"delete",dimensions:"16px"})],8,n$)],40,t$))),128))])]),m("div",i$,[s$,m("ul",null,[(d(!0),v(dt,null,zt(n.defaultOptions,(P,z)=>(d(),v("li",{key:z,class:"ai-type-dropdown__types-item",onMouseover:L=>r.value=z,onMouseleave:T[2]||(T[2]=L=>r.value=null)},[m("button",{onClick:L=>E.$emit("select-option",z)},w(z),9,l$)],40,a$))),128))])])])):B("",!0),r.value?(d(),v("div",r$,w(p.value),1)):B("",!0)]),m("dialog",{ref_key:"dialogRef",ref:s,class:"dialog-content",onClose:y},[m("form",{class:"dialog-content__form",onSubmit:T[5]||(T[5]=Yt(()=>{},["prevent"]))},[m("h2",null,w(u.value?"Update Type":"Add Type"),1),m("label",null,[d$,O(m("input",{"onUpdate:modelValue":T[3]||(T[3]=P=>a.value=P),disabled:u.value,type:"text",required:""},null,8,c$),[[wp,a.value]])]),m("label",null,[u$,O(m("textarea",{"onUpdate:modelValue":T[4]||(T[4]=P=>l.value=P),required:""},null,512),[[wp,l.value]]),p$]),m("div",g$,[m("button",{type:"button",class:"dialog-content__form-button",onClick:y}," Cancel "),m("button",{type:"button",class:"dialog-content__form-button",onClick:k},w(u.value?"Update":"Add"),1)])],32)],544)],64))}}),h$=H(m$,[["__scopeId","data-v-c95fc470"]]),b$={class:"ai-type-select"},f$=q({__name:"AiTypeSelect",props:{elementId:{type:String,default:null},blockId:{type:String,default:null}},setup(t){const e=t,{notify:o}=Le(),{getters:n,dispatch:s}=nt(),a=c(()=>n.siteMeta),l=c(()=>n.siteElements),i=c(()=>n.siteBlocks),r=c(()=>e.elementId!==null),u=c(()=>a.value.aiBlockTypes||[]),p=c(()=>a.value.aiElementTypes||[]),g=c(()=>{var Y;return(Y=l.value[e.elementId].aiData)==null?void 0:Y.type}),b=c(()=>{var Y;return(Y=i.value[e.blockId].aiData)==null?void 0:Y.type}),y=c(()=>{var Y;return(Y=l.value[e.elementId].aiData)==null?void 0:Y.index}),k=c(()=>r.value?p.value:u.value),I=c(()=>r.value?!!g.value:!!b.value),E=c(()=>{const Y=r.value?wA:vA;return Object.fromEntries(Object.entries(Y).filter(([F])=>!k.value[F]))}),T=c(()=>r.value?g.value:b.value),P=c(()=>r.value?"aiElementTypes":"aiBlockTypes"),z=c(()=>r.value?p.value:u.value),L=Y=>{const F=Y?{type:Y}:null;s("mergeElementData",{elementId:e.elementId,elementData:{aiData:F}})},D=Y=>{const F=Y?{type:Y}:null;s("updateBlockData",{blockId:e.blockId,blockData:{aiData:F},merge:!0})},$=({name:Y,description:F})=>{if(!{...k.value,...E.value}[Y]){o({message:`Type "${Y}" does not exist. Create new one.`});return}s("setWebsiteSiteMeta",{key:P.value,value:{...z.value,[Y]:F}})},A=({name:Y,description:F})=>{if(k.value[Y]){o({message:`Type "${Y}" already exists. Choose another one`});return}s("setWebsiteSiteMeta",{key:P.value,value:{...z.value,[Y]:F}})},M=Y=>r.value?L(Y):D(Y),U=Y=>{if(Object.values(r.value?l.value:i.value).some(K=>{var Z;return((Z=K.aiData)==null?void 0:Z.type)===Y})){o({message:`Type "${Y}" is used and cannot be deleted. Ensure that no elements or sections are using this type.`});return}const{[Y]:W,...V}=z.value;s("setWebsiteSiteMeta",{key:P.value,value:V})};return(Y,F)=>(d(),v("div",b$,[h(h$,{"custom-options":k.value,"default-options":E.value,"selected-option":T.value,"has-ai-type":I.value,onSelectOption:M,onAddNewType:A,onEditType:$,onDeleteType:U},null,8,["custom-options","default-options","selected-option","has-ai-type"]),r.value?(d(),S(bs,{key:0,class:"ai-type-select__input","model-value":y.value,type:"number",placeholder:"Index",padding:"8px","onUpdate:modelValue":F[0]||(F[0]=W=>f(s)("mergeElementData",{elementId:e.elementId,elementData:{aiData:{index:W}}}))},null,8,["model-value"])):B("",!0)]))}}),h8=H(f$,[["__scopeId","data-v-09a05107"]]),y$=120,v$={__name:"ControlsTooltip",props:{title:{type:String,default:""}},setup(t){ue(p=>({"49918e8a":i.value,ec4e03a4:r.value}));const{state:e}=nt(),o=C(null),n=C(null),{top:s}=w5(o),a=c(()=>e.gui.isMobileScreen),l=c(()=>o.value?s.value>y$:!1),i=c(()=>{if(!o.value||!n.value)return"0";const{width:p}=n.value.$el.getBoundingClientRect(),{left:g,width:b}=o.value.getBoundingClientRect();return g+b>window.innerWidth?`calc(${-(g+b-window.innerWidth)-24}px)`:`calc(-50% + ${p/2}px)`}),r=c(()=>l.value?"calc(100% + 4px)":"calc(-100% + 4px)"),u=t;return(p,g)=>(d(),S(Mo,{ref_key:"controlsTooltipRef",ref:n,"toggle-event":"hover",mode:"dark",triangle:!1,"use-portal":!1,"hide-tooltip":!u.title||a.value,"content-position":"absolute",class:"controls-tooltip","forced-position":""},{trigger:_(()=>[vt(p.$slots,"default",{},void 0,!0)]),default:_(()=>[u.title&&!a.value?(d(),v("p",{key:0,ref_key:"controlsTooltipContentRef",ref:o,class:"text-body-2"},[j(w(u.title)+" ",1),vt(p.$slots,"shortcut",{},void 0,!0)],512)):B("",!0)]),_:3},8,["hide-tooltip"]))}},mo=H(v$,[["__scopeId","data-v-c43f22b1"]]),_$=q({props:{id:{type:String,default:""},disabled:{type:Boolean,default:!1},modelValue:{type:Boolean,required:!0}},emits:["update:model-value"]}),w$={class:"zyro-toggle"},k$=["id","disabled","checked"],I$=["for"];function S$(t,e,o,n,s,a){return d(),v("div",w$,[m("input",{id:t.id,type:"checkbox",disabled:t.disabled,checked:t.modelValue,class:"zyro-toggle__input",onInput:e[0]||(e[0]=l=>t.$emit("update:model-value",l.target.checked))},null,40,k$),m("label",{for:t.id,class:"zyro-toggle__label"},null,8,I$)])}const Gn=H(_$,[["render",S$],["__scopeId","data-v-d3cda2c4"]]),E$={class:"visibility"},x$={class:"visibility__controls"},T$={class:"visibility__title"},C$={class:"visibility__control"},P$={class:"visibility__control-text-wrapper"},B$={class:"visibility__control-title text-bold-2"},A$={class:"visibility__control-status text-body-2"},D$={class:"visibility__control"},z$={class:"visibility__control-text-wrapper"},$$={class:"visibility__control-title text-bold-2"},L$={class:"visibility__control-status text-body-2"},O$=q({__name:"VisibilityControls",props:{isHiddenDesktop:{type:Boolean},isHiddenMobile:{type:Boolean}},emits:["set-desktop-visibility","set-mobile-visibility"],setup(t){const e=C(null),o=C(!1);return(n,s)=>{var l;const a=ct("qa");return d(),v("div",E$,[O((d(),S(ut,{ref_key:"visibilityControls",ref:e,"button-type":"plain",theme:"highlight",title:n.$t("common.visibility"),onClick:s[0]||(s[0]=i=>o.value=!o.value)},{icon:_(()=>[h(lt,{name:"visibility"})]),_:1},8,["title"])),[[a,"visibility-controls-open-settings"]]),o.value?(d(),S(ve,{key:0,"target-ref":e.value&&((l=e.value)==null?void 0:l.$el),placement:"bottom","auto-update":"",onClickOutside:s[3]||(s[3]=i=>o.value=!1)},{default:_(()=>[m("div",x$,[m("p",T$,w(n.$t("common.visibility"))+": ",1),m("div",C$,[m("div",P$,[m("p",B$,w(n.$t("common.mobile")),1),m("p",A$,w(n.isHiddenMobile?n.$t("common.hidden"):n.$t("common.visible")),1)]),O(h(Gn,{id:"visibility-settings-mobile","model-value":!n.isHiddenMobile,"onUpdate:modelValue":s[1]||(s[1]=i=>n.$emit("set-mobile-visibility",!n.isHiddenMobile))},null,8,["model-value"]),[[a,"visibility-controls-setmobilevisibility"]])]),m("div",D$,[m("div",z$,[m("p",$$,w(n.$t("common.desktop")),1),m("p",L$,w(n.isHiddenDesktop?n.$t("common.hidden"):n.$t("common.visible")),1)]),O(h(Gn,{id:"visibility-settings-desktop","model-value":!n.isHiddenDesktop,"onUpdate:modelValue":s[2]||(s[2]=i=>n.$emit("set-desktop-visibility",!n.isHiddenDesktop))},null,8,["model-value"]),[[a,"visibility-controls-setdesktopvisibility"]])])])]),_:1},8,["target-ref"])):B("",!0)])}}}),b8=H(O$,[["__scopeId","data-v-1646cc59"]]),R$=q({components:{Icon:lt,HostingerButton:ut},props:{position:{validator(t){return["center","right","left","top","bottom"].includes(t)},default:"center"},showCloseButton:{type:Boolean,default:!0},maxWidth:{type:[Number,String],default:"100%"},maxHeight:{type:[Number,String],default:"100%"},width:{type:[Number,String],default:"100%"},height:{type:[Number,String],default:"100%"},minHeight:{type:[Number,String],default:"auto"},overflow:{type:String,default:"auto"},hideBackdrop:{type:Boolean,default:!1},title:{type:String,default:""},subtitle:{type:String,default:""},delay:{type:Number,default:0},noOverflow:{type:Boolean,default:!1},isOverflowVisible:{type:Boolean,default:!1},useFlexForContent:{type:Boolean,default:!1},isRounded:{type:Boolean,default:!0},contentPadding:{type:String,default:""},modalMargin:{type:String,default:""},isTitleCentered:{type:Boolean,default:!1},label:{type:String,default:""},footerPadding:{type:String,default:"16px 24px"},headerPadding:{type:String,default:"16px 24px"},noFooterBorder:{type:Boolean,default:!1},titleClass:{type:String,default:""},isButtonDisabled:{type:Boolean,default:!1}},emits:["close-modal"],setup(){return{hasSlotContent:Hi,DATA_ATTRIBUTE_SELECTOR:ko,DATA_ATTRIBUTE_SELECTOR_MODAL_BACKDROP:Eb}},data(){return{blockClosing:!1,closingTimeout:null,modalId:ie()}},computed:{computedStyles(){return{"--footer-padding":this.footerPadding,"--header-padding":this.headerPadding,"--z-content-padding":this.contentPadding,"--modal-margin":this.modalMargin,"--modal-max-width":this.maxWidth,"--modal-max-height":this.maxHeight,"--modal-width":this.width,"--modal-height":this.height,"--modal-min-height":this.minHeight}},modalRefKey(){return`modal-${this.modalId}`}},created(){window.addEventListener("keydown",this.onEscapeClick)},mounted(){this.delay&&(this.blockClosing=!0,setTimeout(()=>{this.blockClosing=!1},this.delay)),k5(this.$refs[this.modalRefKey],{allowTouchMove:t=>{for(;t&&t!==document.body;){if(t.getAttribute("body-scroll-lock-ignore")!==null)return!0;t=t.parentElement}}})},beforeUnmount(){window.removeEventListener("keydown",this.onEscapeClick),I5(this.$refs[this.modalRefKey])},methods:{onCloseModal(){this.blockClosing||this.$emit("close-modal")},onEscapeClick(t){He(t)===ce.Escape&&this.onCloseModal()}}}),M$={key:1,class:"modal__subtitle text-body-2"},H$={class:"modal__close"},N$={key:0,class:"modal__label text-overline"};function G$(t,e,o,n,s,a){const l=G("Icon"),i=G("HostingerButton"),r=ct("qa");return d(),v("div",Fe({class:["modal-backdrop",[t.position,{hide:t.hideBackdrop}]],style:t.computedStyles,[t.DATA_ATTRIBUTE_SELECTOR||""]:t.DATA_ATTRIBUTE_SELECTOR_MODAL_BACKDROP,onMousedown:e[0]||(e[0]=Yt(u=>t.onCloseModal(),["self","prevent"]))}),[O((d(),v("div",{ref:t.modalRefKey,class:rt(["modal",{"modal--rounded":t.isRounded,"modal--overflow-visible":t.isOverflowVisible,"modal--overflow-hidden":t.noOverflow}]),role:"dialog","aria-labelledby":"modalTitle","aria-describedby":"modalDescription"},[t.title||t.hasSlotContent(t.$slots.title)?(d(),v("h2",{key:0,class:rt(["modal__title",[{"modal__title--has-subtitle":t.subtitle,"text-heading-1":!t.isTitleCentered,"modal__title--centered text-bold-2":t.isTitleCentered},t.titleClass]])},[vt(t.$slots,"title",{},()=>[j(w(t.title),1)],!0)],2)):B("",!0),t.subtitle||t.hasSlotContent(t.$slots.subtitle)?(d(),v("p",M$,[vt(t.$slots,"subtitle",{},()=>[j(w(t.subtitle),1)],!0)])):B("",!0),m("div",{class:rt(["modal__content",{"modal__content--no-overflow":t.noOverflow,"modal__content--display-flex":t.useFlexForContent,"modal__content--overflow-visible":t.isOverflowVisible}]),"body-scroll-lock-ignore":""},[vt(t.$slots,"default",{},void 0,!0)],2),m("div",H$,[t.label?(d(),v("span",N$,w(t.label),1)):B("",!0),t.showCloseButton?O((d(),S(i,{key:1,"button-type":"plain",title:t.$t("common.close"),"is-disabled":t.isButtonDisabled,onClick:t.onCloseModal},{icon:_(()=>[h(l,{name:"close"})]),_:1},8,["title","is-disabled","onClick"])),[[r,"modal-btn-close"]]):B("",!0)]),t.hasSlotContent(t.$slots.footer)?(d(),v("div",{key:2,class:rt(["modal__footer",{"modal__footer--no-border":t.noFooterBorder}])},[vt(t.$slots,"footer",{},void 0,!0)],2)):B("",!0)],2)),[[r,"modal"]])],16)}const je=H(R$,[["render",G$],["__scopeId","data-v-dac60be9"]]),F$={class:"loader"},V$=S5('
',5),U$=[V$],j$=q({__name:"ZyroLoader",props:{color:{default:"var(--color-dark)"},secondaryColor:{default:"transparent"},size:{default:"40px"},weight:{default:"4px"}},setup(t){return ue(e=>({"42b67250":e.size,"75767d07":e.weight,"1338e6f4":e.color,"3bb5d1de":e.secondaryColor})),(e,o)=>(d(),v("div",F$,U$))}}),Ue=H(j$,[["__scopeId","data-v-bc3d69bf"]]),W$=q({__name:"SystemDialogModal",props:{primaryButtonText:{default:""},secondaryButtonText:{default:""},primaryButtonMargin:{default:"0 16px 0 0"},primaryButtonTheme:{default:"text"},secondaryButtonColor:{default:"primary"},title:{default:""},maxWidth:{default:"470px"},width:{default:"auto"},isLoading:{type:Boolean,default:!1},isButtonDisabled:{type:Boolean,default:!1}},emits:["close","click-primary","click-secondary"],setup(t){const e=t,o=c(()=>({"--primary-button-margin":e.primaryButtonMargin}));return(n,s)=>{const a=ct("qa");return d(),S(je,{"max-width":n.maxWidth,"max-height":"auto",height:"auto",width:n.width,class:"choose-placement-modal","content-padding":"0",title:n.title,style:ne(o.value),onCloseModal:s[2]||(s[2]=l=>n.$emit("close"))},{footer:_(()=>[O((d(),S(ut,{class:"choose-placement-modal__primary-button","button-type":n.primaryButtonTheme,onClick:s[0]||(s[0]=l=>n.$emit("click-primary"))},{default:_(()=>[j(w(n.primaryButtonText),1)]),_:1},8,["button-type"])),[[a,"systemdialogmodal-primary-btn"]]),O((d(),S(ut,{theme:n.secondaryButtonColor,"is-disabled":n.isButtonDisabled,onClick:s[1]||(s[1]=l=>n.$emit("click-secondary"))},{default:_(()=>[n.isLoading?(d(),S(Ue,{key:0,size:"26px",color:"var(--color-light)",weight:"3px"})):(d(),v(dt,{key:1},[j(w(n.secondaryButtonText),1)],64))]),_:1},8,["theme","is-disabled"])),[[a,"systemdialogmodal-secondary-btn"]])]),default:_(()=>[m("div",{class:rt(["choose-placement-modal__content",{"choose-placement-modal__content--has-title":n.title}])},[vt(n.$slots,"default",{},void 0,!0)],2)]),_:3},8,["max-width","width","title","style"])}}}),tn=H(W$,[["__scopeId","data-v-27f18ff5"]]),Ll=C(null),Ol=C(null),Su=C(null),Il=()=>{const t=C(!1),e=c(()=>!Ll.value||!Ol.value?null:{clientX:Ll.value,clientY:Ol.value}),o=s=>{Ll.value=s.clientX,Ol.value=s.clientY,Su.value=s},n=()=>{Su.value&&(Ll.value=null,Ol.value=null,Su.value=null)};return Rt([Ll,Ol],([s,a])=>{t.value&&s&&a&&(t.value=!1)}),{isContextMenuWithTriggerActive:t,mousePositionX:Ll,mousePositionY:Ol,mousePosition:e,mouseEventRaw:Su,openContextMenu:o,closeContextMenu:n}},q$=(t,e,o)=>{if(!t||!e)return{left:e.left,top:e.top};const{left:n,top:s}=o,{width:a,height:l}=t.getBoundingClientRect(),{height:i,width:r}=e.getBoundingClientRect();let{left:u,top:p}=o;return n+a>r&&(u-=a),s+l>i&&(p-=a),{left:u,top:p}},Lo=t=>`[${ko}=${t}]`,Y$=({selector:t,event:e})=>{var o;if(!((o=e==null?void 0:e.target)!=null&&o.closest))return!1;switch(t){case x4:return e.target.closest(Lo(Eb))||e.target.closest(Lo(Xf))||e.target.closest(Lo(Z5))||e.target.closest(Lo(Q5))||e.target.closest(Lo(Xa))||e.target.closest(Lo(Od))||e.target.closest(Lo(X5))||e.target.closest(Lo(t0));case XC:return e.target.closest(Lo(Eb));case E4:return e.target.closest(Lo(Ld))||e.target.closest(Lo(nC))||e.target.closest(Lo(Od))||e.target.closest(Lo(Xa));case T4:return e.target.closest(Lo(J5));case C4:return e.target.closest(Lo(Xa))||e.target.closest(Lo(t4))||e.target.closest(Lo(Jf))||e.target.closest(Lo(e4));case P4:return e.target.closest(Lo(Od))||e.target.closest(Lo(Wd));case Ld:return e.target.closest(Lo(Xa));case B4:return e.target.closest(Lo(o4));default:return!1}},ia=({preventSelector:t,target:e},o)=>{oa(e,n=>{var l;const s=Y$({selector:t,event:n});!((l=n==null?void 0:n.target)!=null&&l.closest)||s||o(n)})},K$={__name:"ContextMenu",props:{isEnabled:{type:Boolean,default:!1},triggerRef:{type:Element,default:null},isElement:{type:Boolean,default:!1}},emits:["close-context-menu"],setup(t,{emit:e}){ue(b=>({"240ff3da":l.value,"5deabe22":i.value}));const o=t,n=e,s=C(null),a=C(null),l=C(""),i=C(""),r=C(!1),{mousePosition:u,closeContextMenu:p}=Il(),g=()=>{const{clientX:b,clientY:y}=(u==null?void 0:u.value)??{},{left:k,top:I}=q$(s.value,document.body,{left:b,top:y}),E=o.isElement?document.querySelector(`div.${jf}`).scrollTop:document.querySelector("body").scrollTop;i.value=`${k}px`,l.value=`${I+E}px`};return Rt(u,async b=>{r.value=!1,b&&(r.value=!0,await $e(),s.value&&g())}),ia({target:o.targetRef?a:s,preventSelector:Ld},()=>{p(),n("close-context-menu")}),(b,y)=>t.triggerRef?(d(),S(ve,{key:0,ref_key:"contextMenuPopupRef",ref:a,"target-ref":t.triggerRef,"auto-update":"",placement:"bottom-start","is-mobile-fixed-to-bottom":""},{default:_(()=>[m("div",Fe({class:"context-menu",[f(ko)||""]:f(Ld)}),[vt(b.$slots,"default",{},void 0,!0)],16)]),_:3},8,["target-ref"])):r.value&&t.isEnabled?(d(),v("div",{key:1,ref_key:"contextMenuRef",ref:s,class:"context-menu context-menu--absolute",onMousedown:y[0]||(y[0]=Yt(()=>{},["stop"]))},[m("div",Fe({[f(ko)||""]:f(Ld)}),[vt(b.$slots,"default",{},void 0,!0)],16)],544)):B("",!0)}},f8=H(K$,[["__scopeId","data-v-0064cdda"]]),fa=()=>navigator.userAgent.toUpperCase().includes("MAC"),Z$=["disabled"],Q$={key:0,class:"context-menu-button__icon"},X$={key:1,class:"context-menu-button__shortcut"},J$={__name:"ContextMenuButton",props:{icon:{type:String,default:null},title:{type:String,required:!0},shortcut:{type:Object,default:null,validator:t=>"mac"in t&&"windows"in t},isDisabled:{type:Boolean,default:!1}},setup(t){const e=fa();return(o,n)=>{const s=ct("qa");return O((d(),v("button",{class:"context-menu-button text-body-2",disabled:t.isDisabled},[t.icon?(d(),v("span",Q$,[h(lt,{name:t.icon},null,8,["name"])])):B("",!0),j(" "+w(t.title)+" ",1),t.shortcut?(d(),v("span",X$,w(f(e)?t.shortcut.mac:t.shortcut.windows),1)):B("",!0)],8,Z$)),[[s,`context-menu-${t.title}-btn`]])}}},zn=H(J$,[["__scopeId","data-v-f49f28e0"]]),tL={},eL={class:"separator"};function oL(t,e){return d(),v("hr",eL)}const ye=H(tL,[["render",oL],["__scopeId","data-v-9b4a195a"]]),nL=200,iL=200,sL="var(--color-dark)",aL="rectangle",lL=' ',rL=[{name:"rectangle"},{name:"ellipse"},{name:"triangle"},{name:"rhombus"},{name:"hexagon"},{name:"octagon"},{name:"star"},{name:"dodecagram"},{name:"horizontal-line"},{name:"bolded-horizontal-line"},{name:"dotted-horizontal-line"},{name:"dashed-horizontal-line"},{name:"vertical-line"},{name:"bolded-vertical-line"},{name:"dotted-vertical-line"},{name:"dashed-vertical-line"}],y8={facebook:{link:"https://www.facebook.com/",icon:"facebook",svg:' '},instagram:{link:"https://www.instagram.com/",icon:"instagram",svg:' '},linkedin:{link:"https://www.linkedin.com/",icon:"linkedin-in",svg:' '},twitter:{link:"https://www.twitter.com/",icon:"twitter",svg:' '}},dL=({elementId:t,elementPositionKey:e,elementWidth:o})=>{const n=e==="mobile",s=document.querySelector(".app"),a=document.createElement("div"),l=document.querySelector(`[${_c}='${t}']`).cloneNode(!0),i=n?ei:Ji,r=n?Li:0;a.style.position="fixed",a.style.visibility="hidden",a.style.width=`${i}px`,a.style.height="100%",a.style.padding=`0px ${r}px`,l.style.width=`${o}px`,n&&a.classList.add("zyro-mb-preview"),s.appendChild(a),a.appendChild(l);const p=l.querySelector(`[data-element-ref='${t}']`).offsetHeight;return a.remove(),p},Gi=()=>{const{getters:t,dispatch:e}=nt(),o=c(()=>t["gui/isMobileMode"]),n=c(()=>t.siteElements),s=c(()=>t.siteBlocks),a=c(()=>o.value?ge:se);return{updateElementHeightOnDevices:async({elementId:i,blockId:r})=>{await $e();const u=r||Vg({elementId:i,siteBlocks:s.value}),p=s.value[u],g=n.value[i],{top:b,width:y}=g[a.value],k=dL({elementId:i,elementPositionKey:a.value,elementWidth:y});if(e("mergeElementData",{elementId:i,elementData:{[a.value]:{height:k}}}),o.value)return;const I=k-g.mobile.height;Object.values((p==null?void 0:p.components)||{}).filter(E=>E!==i).forEach(E=>{const{top:T}=n.value[E].mobile,P=T+I<=0?b+k:T+I;Tt!=null&&t.length?Math.max(...t.map(o=>o[e].top+o[e].height)):0,eg=({position:t})=>t?["top","left","width","height"].every(o=>{const n=o in t,s=typeof t[o]=="number"&&t[o]>=0;return n&&s}):!1,cL=200,uL=[Po,js,zi,Ws,Ni],pL=[na,Hn,es,_n,_l],gL=[na,Hn,es],mL=({elementType:t,elementRawPosition:e,isDesktopMode:o,lowestElementBottom:n})=>{const{rawTop:s,rawLeft:a,rawHeight:l,rawWidth:i}=e,r=pL.includes(t),u=gL.includes(t),p=r?i:Ns;if(o){const g=r?l:cL,b=n+b7;return $n({width:p,left:a,height:g,top:b},Ns,u)}return $n({width:p,left:a,height:l,top:s},Ns)},hL=({elementRawPosition:t,isDesktopMode:e,lowestElementBottom:o})=>{const{rawTop:n,rawLeft:s,rawHeight:a,rawWidth:l}=t;return $n(e?{width:l,left:s,height:a,top:n}:{width:l,left:s,height:a,top:o+f7},ar)},R2=({elementPosition:t,blockPosition:e})=>{const{rawTop:o,rawLeft:n}=t,{top:s,left:a}=e;return{...t,rawTop:Math.max(Math.round(o-s),0),rawLeft:Math.max(Math.round(n-a),0)}},za=()=>{const{t}=_t(),{isAiBuilderMode:e}=vo(),{getters:o,dispatch:n}=nt(),{updateElementHeightOnDevices:s}=Gi(),a=c(()=>o["gui/isMobileMode"]),l=c(()=>!a.value),i=c(()=>a.value?se:ge),r=c(()=>o.isCurrentPagePrivate),u=c(()=>({text:{name:t("common.text"),icon:"text",width:4,widthPixels:400,heightPixels:78,height:3,content:{type:Po,content:`${t("builder.elements.defaultTextElementText")} `,settings:{styles:{"m-element-margin":"0 0 16px 0",text:"left",align:"flex-start",justify:"flex-start"}}}},button:{name:t("common.button"),icon:"button",width:3,widthPixels:130,heightPixels:50,height:2,content:{backgroundColor:"rgb(0, 0, 0)",backgroundColorHover:"rgb(29, 30, 32)",fontColor:"rgb(255, 255, 255)",fontColorHover:"rgb(255, 255, 255)",borderColor:"rgb(0, 0, 0)",borderColorHover:"rgb(0, 0, 0)",type:Hn,content:"Button",href:"",linkType:"page",rel:"",settings:{type:"primary",styles:{"m-element-margin":"0 0 16px 0",align:"center",justify:"center"}}}},...e.value||r.value?{}:{ecommerceButton:{name:t("builder.addToBag"),icon:"add-to-bag",width:4,widthPixels:150,heightPixels:50,height:2,content:{backgroundColor:"rgb(0, 0, 0)",backgroundColorHover:"rgb(29, 30, 32)",fontColor:"rgb(255, 255, 255)",fontColorHover:"rgb(255, 255, 255)",borderColor:"rgb(0, 0, 0)",borderColorHover:"rgb(0, 0, 0)",type:es,content:"Add to bag",settings:{href:"#",type:"primary",styles:{"m-element-margin":"0 0 16px 0",align:"center",justify:"center"}}}}},image:{name:t("common.image"),icon:"image",width:4,widthPixels:480,heightPixels:320,height:6,content:{type:_n,rel:"nofollow",settings:{alt:"Bright living room with modern inventory",origin:"other",path:"https://assets.zyrosite.com/bed-and-breakfast/images/amenities.jpg",clickAction:"none",styles:{"m-element-margin":"0 0 16px 0",align:"center",justify:"center"}}}},gallery:{name:t("common.gallery"),icon:"gallery",width:9,widthPixels:640,heightPixels:312,height:2,content:{type:zi,settings:{layout:"grid",imageClickAction:"lightbox",styles:{"m-element-margin":"0 0 16px 0"}},desktop:{columnGap:16,columnCount:4},mobile:{columnGap:12,columnCount:2},images:[{origin:"other",path:`${ua}/blue-oval-spheres.png`,alt:"Blue oval spheres"},{origin:"other",path:`${ua}/green-leaves-in-mist.png`,alt:"Green leaves in mist"},{origin:"other",path:`${ua}/microscope-bubbles.png`,alt:"Microscope bubbles"},{origin:"other",path:`${ua}/microscope-water-bubbles.png`,alt:"Microscope water bubbles"},{origin:"other",path:`${ua}/orange-to-blue-gradient.png`,alt:"Orange to blue gradient"},{origin:"other",path:`${ua}/white-ball-on-green-floor.png`,alt:"White ball on green floor"},{origin:"other",path:`${ua}/white-flower-in-pink-background.png`,alt:"White flower in pink background"},{origin:"other",path:`${ua}/woman-with-flowers-in-hair.png`,alt:"Woman with flowers in hair"}]}},video:{name:t("common.video"),icon:"video",width:5,widthPixels:480,heightPixels:270,height:5,content:{type:Ba,settings:{src:"https://www.youtube.com/embed/c8aFcHFu8QM",styles:{"m-element-margin":"0 0 16px 0",align:"center",justify:"center"}}}},shape:{name:t("common.shape"),icon:"shape",widthPixels:nL,heightPixels:iL,content:{type:na,svg:lL,shape:aL,color:sL}},map:{name:t("common.map"),icon:"map",width:5,widthPixels:480,heightPixels:320,height:5,content:{type:Pa,settings:{"m-element-margin":"0 0 16px 0",src:"https://maps.google.com/maps?q=697 Hilltop Street, Springfield, MA, USA&t=&z=13&ie=UTF8&iwloc=&output=embed",styles:{align:"center",justify:"center"}}}},instagramFeed:{name:t("common.instagramFeedV2"),icon:"instagram",width:10,widthPixels:640,heightPixels:312,height:5,content:{type:Ws,settings:{username:null,"item-count":8,styles:{"m-element-margin":"0 0 16px 0","items-per-row":4,"m-items-per-row":3,"item-gap":"16px","m-item-gap":"8px",align:"center",justify:"flex-start"}}}},form:{name:t("common.contactFormRsvp"),icon:"contact",width:5,widthPixels:400,heightPixels:500,height:5,content:{type:js,formId:"Contact form",settings:{successMessage:"Thank You!",schema:[{fieldType:"short-answer",id:"firstName",name:"Name",inputLabel:"Name",validation:[["optional"]],"validation-messages":{required:"This field is required"},placeholder:"Your name",type:"GridInput",svg:"align-left-short",validationType:"text"},{fieldType:"short-answer",id:"lastName",name:"Last name",inputLabel:"Last name",validation:[["optional"]],"validation-messages":{required:"This field is required"},placeholder:"Your last name",type:"GridInput",svg:"align-left-short",validationType:"text"},{fieldType:"short-answer",id:"email",name:"Short answer email",inputLabel:"Your email",validation:[["bail"],["email"],["required"]],"validation-messages":{required:"This field is required",email:"Please enter a valid email address"},placeholder:"Your email address",type:"GridInput",svg:"align-left-short",validationType:"email"},{id:"message",tag:"textarea",inputLabel:"Message",name:"Paragraph",validation:[["required"]],"validation-messages":{required:"This field is required"},placeholder:"Enter your message",type:"GridInput",svg:"align-left"}],theme:"light",styles:{"m-element-margin":"0 0 16px 0",justify:"center",formSpacing:"22px 10px"}},submitButtonBackgroundColor:"rgb(0, 0, 0)",submitButtonBackgroundColorHover:"rgb(29, 30, 32)",submitButtonFontColor:"rgb(255, 255, 255)",submitButtonFontColorHover:"rgb(255, 255, 255)",submitButtonBorderColor:"rgb(0, 0, 0)",submitButtonBorderColorHover:"rgb(0, 0, 0)",labelTextColor:"rgb(26, 26, 26)",inputTextColor:"rgb(26, 26, 26)",inputBorderColor:"rgb(26, 26, 26)",inputFillColor:"rgb(241, 241, 241)",inputFillColorHover:"rgb(241, 241, 241)",submitButtonData:{type:"GridButton",content:"Submit",settings:{type:"primary",isFormButton:!0,styles:{align:"center",justify:"center",position:"8/8/9/10"}}},innerBackground:{current:"",color:"rgb(255, 255, 255)",image:""}}},subscribeForm:{name:t("common.subscribe"),icon:"subscribe",width:5,widthPixels:300,heightPixels:200,height:5,content:{type:js,formId:mp,settings:{type:"singleField",successMessage:"Thank you!",schema:[{svg:"align-left-short",fieldType:"short-answer",id:"email",name:"email",inputLabel:"Email address",validation:[["required"],["bail"],["email"]],"validation-messages":{required:"Email is required",email:"Please enter a valid email address"},placeholder:"Your email address",type:"GridInput",validationType:"email"}],theme:"light",styles:{"m-element-margin":"0 0 16px 0",align:"space-between",text:"left",justify:"center",formSpacing:"22px 10px"}},submitButtonBackgroundColor:"rgb(0, 0, 0)",submitButtonBackgroundColorHover:"rgb(29, 30, 32)",submitButtonFontColor:"rgb(255, 255, 255)",submitButtonFontColorHover:"rgb(255, 255, 255)",submitButtonBorderColor:"rgb(0, 0, 0)",submitButtonBorderColorHover:"rgb(0, 0, 0)",labelTextColor:"rgb(26, 26, 26)",inputTextColor:"rgb(26, 26, 26)",inputBorderColor:"rgb(26, 26, 26)",inputFillColor:"rgb(241, 241, 241)",inputFillColorHover:"rgb(241, 241, 241)",submitButtonData:{type:"GridButton",content:"Submit",settings:{type:"primary",isFormButton:!0,styles:{align:"center",position:"8/8/9/10"}}},innerBackground:{current:"",color:"rgb(255, 255, 255)",image:""}}},socialIcons:{name:t("common.socialIcons"),icon:"social-links",width:2,widthPixels:200,heightPixels:25,height:1,content:{type:Ni,settings:{useBrandColors:!1,styles:{"m-element-margin":"0 0 16px 0",align:"",justify:"center","space-between-icons":"20px","icon-direction":"row","icon-color":"rgb(0, 0, 0)","icon-color-hover":"rgb(58, 58, 58)","icon-spacing":"space-around","icon-size":"20px"}},links:[...Object.values(y8)]}},embed:{name:t("common.embedCode"),width:6,widthPixels:400,heightPixels:22,height:6,icon:"html-brackets",content:{type:vl,content:"Your custom embed code
",settings:{styles:{}}}},...r.value?{}:{searchBar:{name:t("common.productSearch"),widthPixels:328,heightPixels:48,icon:"search",content:{type:_l,placeholderText:t("builder.searchBarDefaultPlaceholder"),noResultsText:t("builder.searchBarDefaultNoResultsText"),fillColor:"rgb(255, 255, 255)",fillColorHover:"rgb(255, 255, 255)",resultItemHoverColor:"rgba(0, 0, 0, 0.06)",textAndIconColor:"rgb(114, 117, 134)",textAndIconColorHover:"rgb(29, 30, 32)",borderColor:"rgb(218, 220, 224)",borderColorHover:"rgba(29, 30, 32)",borderRadius:4,fontFamily:"Roboto"}}}}));return{addLayoutElement:async({blockElements:g,blockId:b,blockToAddRef:y,elementId:k,newElementData:I,newElementRawPosition:E,newElementRelativePosition:T=Wp.BOTTOM})=>{const{newElementRawLeft:P=0,newElementRawTop:z=0,newElementRawWidth:L,newElementRawHeight:D}=E,$=!g.length,A=lc({blockElements:g,elementPositionKey:ge}),M=lc({blockElements:g,elementPositionKey:se}),U=a.value?M:A,Y=y.getBoundingClientRect(),{left:F,top:W,height:V,width:K}=Y,Z={rawLeft:P,rawTop:z,rawHeight:D,rawWidth:L};if(T===Wp.BOTTOM){const ft=W+(V/2-D/2),tt=$?ft:W+U,gt=F+(K/2-L/2);Z.rawTop=z+tt,Z.rawLeft=gt}const N=hL({elementRawPosition:R2({elementPosition:Z,blockPosition:Y}),isDesktopMode:l.value,lowestElementBottom:A}),X=mL({elementType:I.type,elementRawPosition:R2({elementPosition:Z,blockPosition:Y}),isDesktopMode:l.value,lowestElementBottom:M}),et=eg({position:N}),pt=eg({position:X});if(!et||!pt){Se({category:"LAYOUT_INVALID_POSITION",message:"Add element",data:{positionKey:et?"mobile":"desktop",position:et?X:N,elementId:k},level:"debug",type:"debug"}),jt(new Error("Invalid element position")),n("notifications/notify",{messageI18nKeyPath:"builder.notifications.errorWhileAddingElement"});return}n("addElement",{blockId:b,elementId:k,elementData:{...I,desktop:{...I.desktop,...N},mobile:{...I.mobile,...X}}}),await $e();const st=a.value?Ns:ar,J=$n(Sr({elementId:k,blockId:b,leftOffset:a.value?Li:0}),st);n("mergeElementData",{elementId:k,elementData:{[i.value]:J}}),uL.includes(I.type)&&s({elementId:k}),n("undoRedo/createSnapshot");const it=I.formId===mp,at=yA[it?mp:I.type];document.querySelector(`[${_c}="${k}"]`).scrollIntoView({block:"end",behavior:"smooth"}),Et.logEvent({eventName:"website_builder.add_element.element_added",eventProperties:{element_name:at}})},defaultElements:u}},M2=C(null),bL=C(null),fL=C(null),H2=C(null),yL=C(null),vL=C(null),_L=C(!1),Sl=()=>({selectedLayoutBlockId:M2,copiedLayoutBlockId:bL,selectedLayoutElementId:H2,copiedElementId:yL,copiedElementLocale:vL,isElementCut:_L,copiedLayoutBlockLocale:fL,setSelectedLayoutBlockId:o=>{M2.value=o},setSelectedLayoutElementId:o=>{H2.value=o}}),nn=Wo(en.USER,()=>{const t=C(null),e=C(!1),o=C(!1),n=C(!1),s=c(()=>{var p;return(p=t.value)==null?void 0:p.hPanelId}),a=c(()=>{var g;const{tld:p}=_z(((g=t.value)==null?void 0:g.resellerUrl)||"");return p}),l=p=>{e.value=p},i=p=>{o.value=p},r=p=>{n.value=p},u=({userData:p})=>{t.value=p,uD(a.value)};return window.hwbToggleAiTools=()=>{i(!o.value),r(!n.value)},{user:t,userHpanelId:s,areFeaturesLocked:e,isAiTypeSelectionVisible:o,isJsonClipboardEnabled:n,userResellerTld:a,setUser:u,setAreFeaturesLocked:l}}),wL=x.union([x.literal("left"),x.literal("right"),x.literal("center"),x.literal("justify"),x.literal("start"),x.literal("end"),x.literal("match-parent")]),kL=x.union([x.literal("stretch"),x.literal("center"),x.literal("flex-start"),x.literal("flex-end"),x.literal("baseline"),x.literal("initial"),x.literal("inherit")]),v8=x.union([x.literal("flex-start"),x.literal("flex-end"),x.literal("center"),x.literal("space-between"),x.literal("space-around"),x.literal("space-evenly"),x.literal("initial"),x.literal("inherit")]),_8=x.union([x.literal("alternate"),x.literal("author"),x.literal("bookmark"),x.literal("external"),x.literal("help"),x.literal("license"),x.literal("next"),x.literal("nofollow"),x.literal("noopener"),x.literal("noreferrer"),x.literal("prev"),x.literal("search"),x.literal("tag")]),Ai=x.string().min(1),IL=x.union([x.literal("row"),x.literal("row-reverse"),x.literal("column"),x.literal("column-reverse")]),SL=x.string().regex(/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/),EL=x.string().regex(/^rgb\((\d{1,3}),(\d{1,3}),(\d{1,3})\)$/),xL=x.string().regex(/^rgba\((\d{1,3}),(\d{1,3}),(\d{1,3}),(\d(\.\d+)?|1(\.0+)?)\)$/),Xe=x.union([SL,EL,xL]),og=x.string().regex(/^\d+px$/),fs=x.union([x.literal("assets"),x.literal("unsplash"),x.literal("other")]),TL=x.union([x.literal("var(--font-primary)"),x.literal("var(--font-secondary)")]),N2=x.string().regex(/^(?:[1-9][0-9]*|[1-9])px$/),CL=x.string().regex(/^(normal|italic|oblique(?: -?(?:[1-8]?[0-9]|90)deg)?)$/),w8=x.union([x.literal(100),x.literal(200),x.literal(300),x.literal(400),x.literal(500),x.literal(600),x.literal(700),x.literal(800),x.literal(900),x.literal("normal"),x.literal("bold")]),PL=x.string().regex(/^(0|[1-9]\d*|0?\.\d+|\d+\.\d+)(em|rem)?$|^[1-9]\d*px$|^normal$/),BL=x.union([x.literal("none"),x.literal("underline"),x.literal("underline")]),AL=x.union([x.literal("capitalize"),x.literal("uppercase"),x.literal("lowercase"),x.literal("none")]),DL=x.string().regex(/^(-?\d+(\.\d+)?(em|rem)|-?\d+(px)|normal|(\.\d+)(em|rem)|0)$/),Eu=x.string().regex(/^(?:\d+(\.\d+)?(em|rem)|\d+px|0|(\.\d+)(em|rem))$/),zL=x.number().min(0).max(999),G2=x.string().regex(/^(?:\d+(\.\d+)?(em|rem)|\d+px|none|0|(\.\d+)(em|rem))?$/),pa=x.string().regex(/^(-?\d+(\.\d+)?(em|rem)|-?\d+(px)|(\.\d+)(em|rem)|0)$/),$L=x.string().regex(/^(?:0|[1-9]\d*(?:\.\d+)?(ms|s)|0?\.\d+(ms|s))$|^initial$/),LL=x.union([x.literal("outlined"),x.literal("left"),x.literal("center")]),OL=x.union([x.literal("path"),x.literal("origin"),x.literal("color"),x.literal("gradient"),x.literal("image"),x.literal("video")]),RL=x.string().regex(/^(|pcol_.*)$/),ML=x.union([x.literal("right"),x.literal("left"),x.literal("center")]),k8=x.union([x.literal("global"),x.literal("element")]),I8=x.union([x.literal("right"),x.literal("left"),x.literal("center")]),HL=x.string().regex(/^new Set(t).size===t.length,TO=t=>Sg.map(o=>o.country).includes(t),CO=t=>dl.some(e=>e.value===t),PO=({ctx:t,locale:e,country:o,flagPath:n,name:s,languageCode:a})=>{const l=Sg.filter(r=>e===r.locale);o!==null&&!l.some(r=>r.country===o)&&t.addIssue({code:x.ZodIssueCode.custom,message:"language country is not valid for locale"}),n||t.addIssue({code:x.ZodIssueCode.custom,message:"flagPath is required when locale is set"}),l.some(r=>r.flagPath===n)||t.addIssue({code:x.ZodIssueCode.custom,message:"language flag path is not valid for locale"}),l.some(r=>r.flagPath===n&&(r.languageCode===a||!r.languageCode))||t.addIssue({code:x.ZodIssueCode.custom,message:"language languageCode is not valid for locale"}),s||t.addIssue({code:x.ZodIssueCode.custom,message:"name is required when locale is set"})},BO=(t,e,o,n)=>{if(t.linkType===Io.PAGE){const s=t;o.includes(s.linkedPageId)||n.addIssue({code:x.ZodIssueCode.custom,message:"linkedPageId is not found in pages"})}if(t.linkType===Io.LINK){const s=t,a=s.innerLinkType===oe.PAGE,l=s.innerLinkType===oe.ANCHORED_SECTION,i=s.innerLinkType===oe.EMAIL,r=s.innerLinkType===oe.PHONE,u=s.innerLinkType===oe.EXTERNAL,p=s.innerLinkType===oe.DOWNLOAD;a&&!o.includes(s.innerLinkPageId)&&n.addIssue({code:x.ZodIssueCode.custom,message:`${s.innerLinkPageId} - innerLinkType is not found in pages`}),l&&(e.includes(s.innerLinkPageId)||n.addIssue({code:x.ZodIssueCode.custom,message:`${s.innerLinkPageId} - innerLinkType is not found in sections`}),s.href.includes(s.innerLinkPageId)||n.addIssue({code:x.ZodIssueCode.custom,message:`${s.innerLinkPageId} - section innerLinkType is not found in href`}),s.href.startsWith(Un.BASE)||n.addIssue({code:x.ZodIssueCode.custom,message:`${s.href} - section href not starting with ${Un.BASE}`})),i&&!s.href.startsWith(Un.EMAIL)&&n.addIssue({code:x.ZodIssueCode.custom,message:`${s.href} - email href not starting with ${Un.EMAIL}`}),r&&!s.href.startsWith(Un.TEL)&&n.addIssue({code:x.ZodIssueCode.custom,message:`${s.href} - phone href not starting with ${Un.TEL}`}),u&&!s.href.startsWith(Un.HTTP)&&!s.href.startsWith(Un.HTTPS)&&n.addIssue({code:x.ZodIssueCode.custom,message:`${s.href} - external href not starting with ${Un.HTTP} or ${Un.HTTPS}`}),p&&!s.href.startsWith(Un.HTTPS)&&n.addIssue({code:x.ZodIssueCode.custom,message:`${s.href} - download href not starting with ${Un.HTTPS}`})}},AO=(t,e,o,n)=>{const s=t.flatMap(l=>{var i;return l.linkType===Io.FOLDER&&((i=l.subItems)!=null&&i.length)?[l,...l.subItems]:l}).map(l=>(BO(l,e,o,n),l.navItemId));new Set(s).size===s.length||n.addIssue({code:x.ZodIssueCode.custom,message:"navItemIds are not unique"})},DO=t=>(e,o)=>{e.forEach(n=>{n&&!Number.isInteger(n)&&t.addIssue({code:x.ZodIssueCode.custom,message:`${n} should be an integer in ${o}`})})},zO=(t,e,o,n)=>{const s=Object.keys(t),a=Object.values(t);s.includes(o)||n.addIssue({code:x.ZodIssueCode.custom,message:"homePageId is not found in pages"}),a.forEach(i=>{var u;const r=((u=i.blocks)==null?void 0:u.filter(p=>!e.includes(p)))||[];if(r.length&&n.addIssue({code:x.ZodIssueCode.custom,message:`not existing blocks - ${r.toString()} found in pages`}),i.type!==$i.PAGE_TYPE_ECOMMERCE_DYNAMIC_PRODUCT){const p=i.meta,g=p==null?void 0:p.keywords,b=p==null?void 0:p.focusKeyword;(g!=null&&g.length||b)&&!(g!=null&&g.includes(b))&&n.addIssue({code:x.ZodIssueCode.custom,message:`focusKeyword - ${b} not found in keywords`})}})},$O=(t,e,o)=>{const n=Object.values(t),s=DO(o);n.forEach(a=>{var r,u,p,g;const{zindexes:l,components:i}=a;if(i!=null&&i.length){const b=i.filter(y=>!e.includes(y));b.length&&o.addIssue({code:x.ZodIssueCode.custom,message:`not existing elements - ${b.toString()} found in block`})}if((i!=null&&i.length||l!=null&&l.length)&&(!(l!=null&&l.every(y=>i==null?void 0:i.includes(y)))||(l==null?void 0:l.length)!==(i==null?void 0:i.length))&&o.addIssue({code:x.ZodIssueCode.custom,message:"zindexes should match components"}),a.type===Go.BLOCK_NAVIGATION&&(s(Object.values(a.mobile),"navigation block mobile"),s(Object.values(a.desktop),"navigation block desktop")),a.type===Go.BLOCK_BLOG_HEADER&&s([(r=a.settings)==null?void 0:r.blogTitleFontSize],"blog header block"),a.type===Go.BLOCK_BLOG_LIST){const{settings:b}=a;s([b.styles.cols,b.styles.rows,b.postColumnCount,b.postsPerPage,b.blogTitleFontSize],"blog list block")}if(a.type===Go.BLOCK_ECOMMERCE_PRODUCT_LIST){const{productsPerPage:b,buttonBorderWidth:y,desktop:k,mobile:I}=a;s([b,y,k==null?void 0:k.rowGap,k==null?void 0:k.columnGap,k==null?void 0:k.columnCount,I==null?void 0:I.rowGap,I==null?void 0:I.columnGap,I==null?void 0:I.columnCount],"ecommerce list block")}if(a.type===Go.BLOCK_ECOMMERCE_PRODUCT){const{buttonBorderWidth:b}=a;s([b],"ecommerce product block")}if(a.type===Go.BLOCK_LAYOUT){const{mobile:b,desktop:y,settings:k,snapRowHeight:I,snapRowGap:E}=a;s([b==null?void 0:b.minHeight,y==null?void 0:y.minHeight,E,I,Number((u=k==null?void 0:k.styles)==null?void 0:u.cols),Number((p=k==null?void 0:k.styles)==null?void 0:p.rows),Number((g=k==null?void 0:k.styles)==null?void 0:g["m-rows"])],"layout block")}if(a.type===Go.BLOCK_IMAGES_SLIDESHOW){const{mobile:b,desktop:y,autoplayInterval:k,slides:I}=a;s([b==null?void 0:b.minHeight,y==null?void 0:y.minHeight,k,...(I==null?void 0:I.map(({fullResolutionWidth:E})=>E).filter(Boolean))||[],...(I==null?void 0:I.map(({fullResolutionHeight:E})=>E).filter(Boolean))||[]],"image slideshow block")}if(a.type===Go.BLOCK_STICKY_BAR){const{mobile:b,desktop:y}=a;s([b==null?void 0:b.minHeight,y==null?void 0:y.minHeight],"sticky bar block")}})},j2=(t,e,o,n)=>{const s=e?Object.keys(e):[];t.every(l=>s.includes(l))||n.addIssue({code:x.ZodIssueCode.custom,message:`blog categories are missing in ${o}`})},L6=Iy.superRefine((t,e)=>{if(t===void 0)return;yf(t)||e.addIssue({code:x.ZodIssueCode.custom,message:"Not all googleAdsIds are unique"})}),O6=Ly.extend({googleAdsIds:L6}),R6=Oy.superRefine((t,e)=>{yf(Object.keys(t))||e.addIssue({code:x.ZodIssueCode.custom,message:"Not all form names are unique"});const n=Object.values(t).map(({token:a})=>a);yf(n)||e.addIssue({code:x.ZodIssueCode.custom,message:"Not all form tokens are unique"})}),M6=$y.superRefine((t,e)=>{const{name:o,country:n,flagPath:s,homePageId:a,locale:l,pages:i,blocks:r,elements:u,cookieBannerAcceptText:p,cookieBannerDeclineText:g,cookieBannerDisclaimer:b,languageCode:y,metaHtmlLanguage:k,nav:I}=t,E=Object.keys(i),T=Object.keys(r),P=Object.keys(u),z=Object.values(r).filter(({type:L})=>L===Go.BLOCK_LAYOUT).map(L=>L.htmlId).filter(L=>!!L||L==="");AO(I,z,E,e),zO(i,T,a,e),$O(r,P,e),CO(k)||e.addIssue({code:x.ZodIssueCode.custom,message:"metaHtmlLanguage is not supported"}),n!=null&&(TO(n)||e.addIssue({code:x.ZodIssueCode.custom,message:"language country is not supported"})),l&&PO({ctx:e,locale:l,country:n,flagPath:s,name:o,languageCode:y}),(p||g||b)&&(!p||!g||!b&&b!=="")&&e.addIssue({code:x.ZodIssueCode.custom,message:"cookie banner texts are missing"})}),H6=x.record(Jg,M6).superRefine((t,e)=>{Object.keys(t).length<1&&e.addIssue({code:x.ZodIssueCode.custom,message:"no languages provided"})}),LO=$6.extend({meta:O6,forms:R6,languages:H6}).superRefine((t,e)=>{const{blogCategories:o,languages:n}=t;Object.values(n).forEach(s=>{const a=Object.values(s.pages).filter(({type:i})=>i===$i.PAGE_TYPE_BLOG);Object.values(s.blocks).filter(({type:i})=>i===Go.BLOCK_BLOG_LIST).forEach(({settings:i})=>{j2(i.categories,o,"blog list block",e)}),a.forEach(({categories:i})=>{j2(i,o,"blog page",e)})})}),ci={...xO,googleAdsIdsSchema:L6,siteMetaSchema:O6,siteFormsSchema:R6,siteLanguageSchema:M6,siteLanguagesSchema:H6,siteDataSchema:LO},OO={validateSiteData:t=>{try{ci.siteDataSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteFonts:t=>{try{t.forEach(e=>{ci.siteFontSchema.parse(e)})}catch(e){throw new Error(e)}},validateSiteForms:t=>{try{ci.siteFormsSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteMeta:t=>{try{ci.siteMetaSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteStyles:t=>{try{ci.siteStylesSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteBuilderCompletedSteps:t=>{try{ci.siteBuilderCompletedStepsSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteLanguages:t=>{try{x.record(ci.siteLanguageSchema).parse(t)}catch(e){throw new Error(e)}},validateSiteLanguage:t=>{try{ci.siteLanguageSchema.parse(t)}catch(e){throw new Error(e)}},validateSitePage:t=>{try{ci.sitePageSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteBlock:t=>{try{ci.siteBlockSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteElement:t=>{try{ci.siteElementSchema.parse(t)}catch(e){throw new Error(e)}},validateSiteElements:t=>{try{x.record(ci.siteElementSchema).parse(t)}catch(e){throw new Error(e)}},validateEcommerceSeoChanges:t=>{try{ci.siteEcommerceSeoChangesSchema.parse(t)}catch(e){throw new Error(e)}}};function RO({languageData:t}){const e=Object.fromEntries(Object.keys(t.blocks).map(a=>[a,Fd(6)])),o=Object.fromEntries(Object.keys(t.elements).map(a=>[a,Fd(6)])),n=Object.fromEntries(Object.entries(t.blocks).map(([a,l])=>{var r,u;return[e[a],{...l,zindexes:((r=l.zindexes)==null?void 0:r.map(p=>o[p]||p))||[],components:((u=l==null?void 0:l.components)==null?void 0:u.map(p=>o[p]||p))||[]}]})),s=Object.fromEntries(Object.entries(t.elements).map(([a,l])=>[o[a]||e[a]||a,l]));return{blocks:n,elements:s}}const MO=()=>{const t=Bt(),{copy:e}=Px(),{notify:o}=Le(),n=C("text/plain"),s=c(()=>t.siteBlocks),a=({blockId:r})=>{const u=s.value[r],p=Object.fromEntries(Object.entries(t.siteElements).filter(([b])=>{var y;return(y=u.components)==null?void 0:y.includes(b)})),g={blocks:{[r]:u},elements:p};return JSON.stringify(g)};return{copyEntireBlockDataToClipboard:({blockId:r})=>{const u=a({blockId:r}),p=new ClipboardItem({[n.value]:new Blob([u],{type:n.value})});e([p])},pasteEntireBlockDataFromClipboard:async({selectedBlockId:r})=>{try{const p=await(await navigator.clipboard.read())[0].getType(n.value),g=JSON.parse(await p.text()||"{}"),b=RO({languageData:g}),y=Object.keys(b.blocks),k=c(()=>{if(!t.currentPage)throw new Error("Error occured while pasting block data, page does not exist");const{blocks:T}=t.currentPage;if(!T)return y;const P=T.indexOf(r);return P===-1?T:T.toSpliced(P+1,0,...y)}),I={...b,pages:{[t.currentPageId]:{blocks:k.value}}};OO.validateSiteBlock(Object.values(I.blocks)[0]);const E=ji(t.currentSiteLanguage,I);t.setSiteLanguageData({locale:t.currentLocale,data:E})}catch(u){o({message:"Failed to paste block from JSON, check console for more details"}),console.error("Error pasting block data from clipboard",u)}}}},HO={class:"block-context-menu"},NO={key:0,class:"block-context-menu__heading"},GO={class:"text-bold-2"},FO={key:1},VO={__name:"ContextMenuLayoutBlock",props:{isEnabled:{type:Boolean,default:!0},blockElements:{type:Array,required:!0},blockId:{type:String,required:!0},triggerRef:{type:Element,default:null},isMobileCopyPasteAllowed:{type:Boolean,default:!1}},emits:["close-context-menu","delete-block"],setup(t,{emit:e}){const o=t,n=e,{selectedLayoutBlockId:s,copiedLayoutBlockId:a,copiedLayoutBlockLocale:l,copiedElementId:i,copiedElementLocale:r,isElementCut:u}=Sl(),{closeContextMenu:p}=Il(),{state:g,getters:b,dispatch:y}=nt(),{addLayoutElement:k}=za(),{copyEntireBlockDataToClipboard:I,pasteEntireBlockDataFromClipboard:E}=MO(),T=Bt(),P=nn(),z=c(()=>T.site),L=c(()=>g.gui.isMobileScreen),D=c(()=>b.isCurrentPagePrivate),$=c(()=>g.currentLocale),A=c(()=>g.currentPageId),M=c(()=>b.siteLanguages),U=c(()=>b.siteBlocks),Y=c(()=>b["gui/isMobileMode"]),F=c(()=>{var ot;return!!((ot=M.value[r.value])!=null&&ot.elements[i.value])}),W=c(()=>{var ot;return((ot=U.value[s.value])==null?void 0:ot.slot)==="footer"}),V=c(()=>Object.values(M.value).some(ot=>ot.blocks[a.value])),K=c(()=>{var ot;return T.isCurrentPageTypeLegacyEcommerceProduct?((ot=U.value[a.value])==null?void 0:ot.type)===yl:!V.value||W.value}),Z=()=>{a.value=s.value,l.value=D.value?Kt:$.value},N=()=>{const{newBlock:ot,newElements:ft,newBlocks:tt}=Nr({siteData:z.value,blockId:a.value,fromLocale:l.value});Se({category:"CLICK:Pasting section",data:{blockType:ot.type,parentBlockId:s.value}}),y("addBlock",{pageId:A.value,blockData:ot,blocks:tt,elements:ft,previousBlockId:s.value})},X=async ot=>{var bt;const ft=(bt=M.value[r.value])==null?void 0:bt.elements[i.value];if(!ft)return;const tt=to(ft),gt=document.querySelector(`[data-block-ref='${o.blockId}']`),Q={newElementRawLeft:ot.clientX,newElementRawTop:ot.clientY,newElementRawWidth:Y.value?tt.mobile.width:tt.desktop.width,newElementRawHeight:Y.value?tt.mobile.height:tt.desktop.height};Se({category:u.value?"CLICK:Cut element":"CLICK:Paste element",data:{elementType:tt.type,parentElementId:i.value}}),await k({blockElements:o.blockElements,blockId:o.blockId,blockToAddRef:gt,elementId:ie(),newElementData:tt,newElementRawPosition:Q,newElementRelativePosition:Wp.EXACT}),u.value&&(y("removeElement",{elementId:i.value,locale:r.value}),u.value=null,i.value=null,r.value=null,y("undoRedo/createSnapshot"))},et=()=>{s.value=null,o.triggerRef?n("close-context-menu"):p()},pt=()=>{Z(),et()},st=()=>{I({blockId:s.value}),et()},J=()=>{N(),et()},it=()=>{E({selectedBlockId:s.value}),et()},at=ot=>{X(ot),et()};return(ot,ft)=>{const tt=ct("qa");return d(),S(f8,{"is-enabled":!!f(s)&&t.isEnabled,"trigger-ref":t.triggerRef,onCloseContextMenu:et},{default:_(()=>[m("div",HO,[L.value?(d(),v("div",NO,[m("p",GO,w(ot.$t("builder.editText.moreOptions")),1),O((d(),S(ut,{"button-type":"plain",title:ot.$t("common.close"),onClick:et},{icon:_(()=>[h(lt,{name:"close"})]),_:1},8,["title"])),[[tt,"mobile-context-menu-btn-close"]])])):B("",!0),!L.value||t.isMobileCopyPasteAllowed?(d(),v("span",FO,[h(zn,{icon:"place_item",title:ot.$t("builder.contextMenu.gridBlock.paste"),disabled:!F.value,onClick:ft[0]||(ft[0]=gt=>at(gt))},null,8,["title","disabled"]),f(P).isJsonClipboardEnabled?(d(),S(zn,{key:0,icon:"place_item",title:ot.$t("builder.contextMenu.gridBlock.pasteSectionFromJson"),onClick:it},null,8,["title"])):B("",!0),f(T).isCurrentPageTypeLegacyEcommerceProduct?B("",!0):(d(),v(dt,{key:1},[h(ye),h(zn,{icon:"content_copy",title:ot.$t("builder.contextMenu.gridBlock.copySection"),disabled:W.value,onClick:pt},null,8,["title","disabled"]),f(P).isJsonClipboardEnabled?(d(),S(zn,{key:0,icon:"content_copy",title:ot.$t("builder.contextMenu.gridBlock.copySectionAsJson"),disabled:W.value,onClick:st},null,8,["title","disabled"])):B("",!0),h(zn,{icon:"place_item",title:ot.$t("builder.contextMenu.gridBlock.pasteSection"),disabled:K.value,onClick:J},null,8,["title","disabled"])],64))])):B("",!0),L.value?(d(),S(zn,{key:2,icon:"delete_outline",title:ot.$t("common.delete"),onClick:ft[1]||(ft[1]=gt=>n("delete-block"))},null,8,["title"])):B("",!0)])]),_:1},8,["is-enabled","trigger-ref"])}}},N6=H(VO,[["__scopeId","data-v-62a174ff"]]),UO={},jO={class:"vertical-separator"};function WO(t,e){return d(),v("hr",jO)}const Vo=H(UO,[["render",WO],["__scopeId","data-v-ba77cac8"]]),qO=[Pa,Ba],YO=({lowestElementBottom:t,sectionMinHeight:e})=>{const n=t>=e?0:e-t;return t?`${n}px`:"1fr"},ng=({blockElementsWithPosition:t})=>{try{const e=t.flatMap(({position:n})=>[n.top,n.height+n.top]);return[...new Set([0,...e])].sort((n,s)=>n-s)}catch(e){console.error(e)}},vf=({rowTopsUniqueSorted:t,columnsLeftUniqueSorted:e,elementPosition:o})=>{const{top:n,left:s,width:a,height:l}=o,i=t.indexOf(n)+1,r=t.indexOf(n+l)+1,u=e.indexOf(s)+1,p=e.indexOf(s+a)+1;return{rowStart:i,rowEnd:r,columnStart:u,columnEnd:p}},ig=({blockElementsWithPosition:t,blockWidth:e})=>{const o=t.flatMap(({position:s})=>[s.left,s.width+s.left]);return[...new Set([0,...o,e])].sort((s,a)=>s-a)},rc=({blockElements:t,elementPositionKey:e})=>t.map(o=>({...o,position:o[e]})),W2=({blockElements:t,elementPositionKey:e,buildResponsiveGrid:o})=>{const n=e===se?Ns:Ji,s=rc({blockElements:t,elementPositionKey:e});return ig({blockElementsWithPosition:s,blockWidth:n}).map((r,u,p)=>u===0?r:r-p[u-1]).filter(r=>r!==0).map(r=>o?`${r/n*100}%`:`${r}px`).join(" ")},KO=({gridRows:t})=>t.filter(e=>e!==0),ZO=({gridRows:t})=>t.map(e=>`${e}px`),QO=({gridRows:t})=>t.map(e=>`minmax(${e}px, auto)`),XO=({gridRows:t,responsiveRows:e,isMobile:o})=>t.map((n,s)=>e.includes(s+1)?"auto":`${n*100/(o?ei:Ji)}vw`),vh=({gridRows:t,lastRowHeight:e})=>`${t.join(" ")} ${e}`,xu=({blockElements:t,elementPositionKey:e,buildResponsiveGrid:o,responsiveRows:n,lowestElementBottom:s,sectionMinHeight:a})=>{const l=e===se,i=rc({blockElements:t,elementPositionKey:e}),u=ng({blockElementsWithPosition:i}).map((y,k,I)=>k===0?y:y-I[k-1]),p=YO({lowestElementBottom:s,sectionMinHeight:a}),g=KO({gridRows:u});if(!o){const y=ZO({gridRows:g});return vh({gridRows:y,lastRowHeight:p})}if(!n){const y=QO({gridRows:g});return vh({gridRows:y,lastRowHeight:p})}const b=XO({gridRows:g,responsiveRows:n,isMobile:l});return vh({gridRows:b,lastRowHeight:p})},q2=({blockElements:t,elementPositionKey:e})=>{const o=rc({blockElements:t,elementPositionKey:e}),n=ng({blockElementsWithPosition:o}),s=ig({blockElementsWithPosition:o,blockWidth:e===se?Ns:Ji});return t.filter(a=>!qO.includes(a.type)).reduce((a,l)=>{const{rowEnd:i,rowStart:r}=vf({rowTopsUniqueSorted:n,columnsLeftUniqueSorted:s,elementPosition:l[e]}),u=i>r?i-r:1,p=[...new Array(u).keys()].map((g,b)=>r+b);return a.some(g=>p.includes(g))?a:[...a,i-1]},[])},JO=(t,e)=>{const o=rc({blockElements:t,elementPositionKey:ge}),n=ng({blockElementsWithPosition:o}),s=ig({blockElementsWithPosition:o,blockWidth:Ji}),a=rc({blockElements:t,elementPositionKey:se}),l=ng({blockElementsWithPosition:a}),i=ig({blockElementsWithPosition:a,blockWidth:Ji});return t.map(r=>{var T;const{rowStart:u,rowEnd:p,columnStart:g,columnEnd:b}=vf({rowTopsUniqueSorted:n,columnsLeftUniqueSorted:s,elementPosition:r.desktop}),{rowStart:y,rowEnd:k,columnStart:I,columnEnd:E}=vf({rowTopsUniqueSorted:l,columnsLeftUniqueSorted:i,elementPosition:r.mobile});return{...r,settings:{...r.settings,styles:{...((T=r.settings)==null?void 0:T.styles)||{},"z-index":e.indexOf(r.elementId)+1,"grid-row":`${u}/${p}`,"grid-column":`${g}/${b}`,"m-grid-row":`${y}/${k}`,"m-grid-column":`${I}/${E}`}}}})},Vc=({blockData:t,siteElements:e,shouldBuildResponsive:o=!0}={})=>{const n=C(o),s=c(()=>t.value.components.map(L=>({...e.value[L],elementId:L}))),a=c(()=>{var L;return(L=s==null?void 0:s.value)!=null&&L.length?lc({blockElements:s.value,elementPositionKey:se}):null}),l=c(()=>{var L;return(L=s==null?void 0:s.value)!=null&&L.length?lc({blockElements:s.value,elementPositionKey:ge}):null}),i=c(()=>{var L,D;return(L=t.value.mobile)!=null&&L.minHeight&&a.value?"auto":`${((D=t.value.mobile)==null?void 0:D.minHeight)||Yp}px`}),r=c(()=>{var L,D;return(L=t.value.desktop)!=null&&L.minHeight&&l.value?"auto":`${(D=t.value.desktop)==null?void 0:D.minHeight}px`}),u=c(()=>t.value.components.some(L=>!e.value[L].mobile)),p=c(()=>xu({blockElements:s.value,elementPositionKey:ge,buildResponsiveGrid:n.value})),g=c(()=>W2({blockElements:s.value,elementPositionKey:ge,buildResponsiveGrid:n.value})),b=c(()=>W2({blockElements:s.value,elementPositionKey:se,buildResponsiveGrid:n.value})),y=c(()=>q2({blockElements:s.value,elementPositionKey:se})),k=c(()=>{var L;return xu({blockElements:s.value,elementPositionKey:se,buildResponsiveGrid:n.value,responsiveRows:y.value,lowestElementBottom:a.value,sectionMinHeight:(L=t.value.mobile)==null?void 0:L.minHeight})}),I=c(()=>xu({blockElements:s.value,elementPositionKey:se,buildResponsiveGrid:n.value})),E=c(()=>q2({blockElements:s.value,elementPositionKey:ge})),T=c(()=>{var L;return xu({blockElements:s.value,elementPositionKey:ge,buildResponsiveGrid:n.value,responsiveRows:E.value,lowestElementBottom:l.value,sectionMinHeight:(L=t.value.desktop)==null?void 0:L.minHeight})}),P=c(()=>JO(s.value,t.value.zindexes)),z=c(()=>{var L;return{"--m-grid-template-rows":k.value,"--t-grid-template-rows":I.value,"--small-desktop-grid-template-rows":T.value,"--grid-template-rows":p.value,"--m-grid-template-columns":b.value,"--grid-template-columns":g.value,"--m-block-min-height":i.value,"--t-block-min-height":`${((L=t.value.mobile)==null?void 0:L.minHeight)||Yp}px`,"--small-desktop-block-min-height":r.value,"--block-min-height":`${t.value.desktop.minHeight}px`}});return{blockElements:s,layoutElements:P,buildResponsiveGrid:n,layoutCSSVars:z,isMobileLegacy:u}},os="https://builder-backend.hostinger.com/v1/ai",G6=({brandName:t,brandDescription:e,websiteType:o,templateId:n,fonts:s,siteId:a,generateImages:l=!0,isHeroImageAiGenerated:i=!1,colors:r,domain:u,txtRecord:p,hostingReferenceId:g})=>Ut.post(`${os}/generate-site-paid`,{brandName:t,websiteDescription:e,websiteType:o,templateId:n,theme:gA,fonts:s,siteName:t,generateImages:l,isHeroImageAiGenerated:i,...a&&{siteId:a},colors:r,domain:u,txtRecord:p,hostingReferenceId:g}),F6=({description:t,brandName:e})=>Ut.post(`${os}/website-type`,{description:t,...e&&{brandName:e}}),tR=({pageDescription:t,siteId:e})=>Ut.post(`${os}/generate-page`,{pageDescription:t,siteId:e},{isRetryNeeded:!0}),eR=({description:t,siteId:e})=>Ut.post(`${os}/generate-section`,{description:t,siteId:e}),wLt=({input:t,locale:e})=>Ut.post(`${os}/template-search`,{input:t,locale:e}),oR=({description:t,width:e,height:o,siteId:n,count:s})=>Ut.post(`${os}/generate-images`,{description:t,width:e,height:o,siteId:n,count:s}),nR=({tone:t,length:e,description:o})=>Ut.post(`${os}/generate-blog-post`,{description:o,tone:t,length:e}),iR=({prompt:t})=>Ut.post(`${os}/generate-text`,{prompt:t}),sR=({imageUrl:t})=>Ut.post(`${os}/seo/alt-tag`,{assetUrl:t}),Y2=({brandDescription:t,keywords:e})=>Ut.post(`${os}/seo`,{text:t,keywords:e}),kLt=({brandName:t,brandDescription:e,templateId:o,siteId:n,domain:s,txtRecord:a,hostingReferenceId:l})=>Ut.post(`${os}/generate-template-site`,{brandName:t,websiteDescription:e,templateId:o,siteId:n,txtRecord:a,hostingReferenceId:l,...s&&{domain:s}},{isRetryNeeded:!0}),K2=({html:t,tagName:e})=>{const{data:o}=vs().data("settings",ws).use(()=>(n,s)=>{s.data.tagsCount=0,_s(n,"element",a=>{a.tagName===e&&(s.data.tagsCount+=1)})}).processSync(t);return o.tagsCount},Z2=({html:t,tagsToMatch:e})=>{const{data:o}=vs().data("settings",ws).use(()=>(n,s)=>{s.data.isMatching=!1,_s(n,"element",a=>{e.includes(a.tagName)&&(s.data.isMatching=!0)})}).processSync(t);return o.isMatching},aR=2e4,lR=2e3,rR=t=>{const e=setInterval(()=>{if(t.readyState!==1){clearInterval(e);return}t.send("keep-alive")},aR)},dR=async({url:t,onMessage:e,onClose:o,enableRepeatMessageProtection:n=!1})=>{const s=new WebSocket(t);return s.recentlySentMessages=[],s.addEventListener("message",e),s.addEventListener("close",o),await new Promise(a=>{const l=()=>{a(),s.removeEventListener("open",l)};s.addEventListener("open",l)}),s.originalClose=s.close,s.close=(...a)=>{s.originalClose(...a),s.removeEventListener("message",e),s.removeEventListener("close",o)},s.originalSend=s.send,s.send=a=>{if(n&&typeof a=="string"&&s.recentlySentMessages.includes(a))return;const i=a;s.originalSend(a),s.recentlySentMessages.push(i),window.setTimeout(()=>{s.recentlySentMessages=s.recentlySentMessages.filter(r=>r!==i)},lR)},rR(s),s},_h=C(!1),wh=C(null),kh=C(!1),tm=()=>{const t=()=>{wh.value=null},e=(a=!1)=>{_h.value=!0,kh.value=a},o=()=>{_h.value=!1,kh.value=!1,t()},n=({x:a,y:l,width:i,height:r})=>{wh.value={x:a,y:l,width:i,height:r}};return{isOverlayVisible:_h,highlightedElementCoordinates:wh,showOverlay:e,hideOverlay:o,setHighlightedElement:({element:a}={})=>{const{x:l,y:i,width:r,height:u}=a.getBoundingClientRect();n({x:l,y:i,width:r,height:u})},setHighlightedElementCoordinates:n,resetHighlightedElement:t,hideOverlayOnClick:kh}},Ih=C(!1),ld=C(null),Tu=C(null),Q2=C(null),X2=C(null),ja=C(null),Uc=()=>{const{showOverlay:t,hideOverlay:e}=tm(),o=i=>{ja.value=i,X2.value=Tu.value[i]},n=({steps:i,stepCountToShow:r=i.length,onEndCallback:u}={})=>{Tu.value=i,Q2.value=r,ld.value=u,o(0),Ih.value=!0,t()},s=()=>{Ih.value=!1,Tu.value=null,ja.value=null,window.localStorage.setItem(VC,!0),e(),ld.value&&(ld.value(),ld.value=null)};return{onboardingStepsCountToShow:Q2,currentOnboardingStepIndex:ja,startOnboarding:n,goToNextOnboardingStep:()=>{ja.value!==Tu.value.length-1?o(ja.value+1):s()},goToPreviousOnboardingStep:()=>{ja.value!==0?o(ja.value-1):s()},endOnboarding:s,onboardingEndCallback:ld,currentOnboardingStep:X2,isOnboardingVisible:Ih}},sg="builder-sidebar",ag="builder-header-btn-publishsite",dc="builder-header-btn-switchview",em=Vd.create({timeout:15e4,headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":"application/json"}}});Ut.interceptors.request.handlers.forEach(t=>em.interceptors.request.use(t.fulfilled,t.rejected));Ut.interceptors.response.handlers.forEach(t=>em.interceptors.response.use(t.fulfilled,t.rejected));em.interceptors.response.use(t=>Tr({...t,data:typeof t.data.data<"u"?t.data.data:t.data}));const cR=em,Pn=Wo(en.DOMAIN,()=>{const{state:t,getters:e,dispatch:o}=nt(),n=nn(),s=Ea(),a=C(""),l=C(null),i=C(!1),r=C(!1),u=C(!1),p=c(()=>{var P;return l.value?(P=l.value)==null?void 0:P.nextBestAction:null}),g=c(()=>p.value===Ve.CONNECT_DOMAIN_TEMPORARY),b=c(()=>p.value?[Ve.MANAGE,Ve.TRANSFER_DOMAIN,Ve.RENEW_DOMAIN,Ve.RESTORE_DOMAIN].includes(p.value):!1),y=P=>{a.value=_y(P)},k=()=>{try{Am.setAxiosInstance(cR),Am.setConfig({WEB_HOSTING_API_URL:"https://hpanel.hostinger.com/api/rest-hosting",HDOMAINS_API_URL:"https://hpanel.hostinger.com/api/domains/api/direct",PREVIEW_DOMAIN:sC})}catch(P){jt(P)}},I=()=>{var L;if(!!((L=e.builderCompletedSteps)!=null&&L.isDomainPropagatedEventSent)||!p.value)return;[Ve.MANAGE,Ve.TRANSFER_DOMAIN,Ve.RENEW_DOMAIN,Ve.PENDING_VERIFICATION].includes(p.value)&&(Et.logEvent({eventName:"website_builder.domain.propagated",eventProperties:{website_id:t.websiteId,domain_name:a.value}}),o("addBuilderCompletedStep",{isDomainPropagatedEventSent:!0}))},E=async()=>{if(n.userHpanelId)try{r.value=!0;const P=await Am.getDomainStatus({domain:a.value,currentClientId:n.userHpanelId});r.value=!1,l.value=P.domainStatus,I()}catch(P){jt(P)}},T=async()=>{try{u.value=!0;const P=s.getResourcesByTypes([ul.FREE_DOMAIN]);i.value=P.some(z=>(z==null?void 0:z.state)===Qp.PENDING)}catch(P){jt(P)}u.value=!1};return{customDomainReadable:c(()=>Mf(a.value)),customDomain:a,domainStatus:l,domainNextBestAction:p,isDomainConnected:b,isEligibleForFreeDomain:i,isStatusLoading:r,isFreeDomainEligibilityLoading:u,isCustomDomainTemporary:g,setCustomDomain:y,setHDomainsStatusConfig:k,fetchDomainStatus:E,fetchFreeDomainEligibility:T}}),Fn=Wo(en.ECOMMERCE_ADMIN,()=>{const t=Bt(),e=Gs(),o=me(),n=fo(),s=C(!1),a=C(""),l=C(!1),i=C(!1),r=async()=>{n.canSave&&await n.saveWebsite()},u=async({isOpen:E,path:T,params:P})=>{if(!E){s.value=!1,a.value="";return}await r();const z=sc({path:T,siteId:t.websiteId,params:{...P,jwt:e.getAuthToken()}});s.value=E,a.value=z};return{shouldUpdateEcommerceData:l,isEcommerceAdminIframeOpen:s,ecommerceAdminIframeSrc:a,setIsEcommerceAdminIframeOpen:u,handleEcommerceAdminMessage:E=>{if(E.data===AA){const{notify:T}=Le();u({isOpen:!1}),T({messageI18nKeyPath:"builder.storeManagerUnavailable"});return}if(typeof E.data=="object"&&E.data[0]===DA){if(t.site.meta.ecommerceStoreId)return;const T=E.data[1];t.setSiteMetaData({key:"ecommerceStoreId",value:T});return}BA!==E.data||l.value||(l.value=!0)},handleEcommerceDataUpdate:async()=>{var T;o.resetProductsList(),await o.initEcommerce({refetch:!0}),i.value=!0,!!o.currentDynamicPageProductId&&o.currentDynamicPageProductId!==-1&&(o.productsSeo.some(z=>z.id===o.currentDynamicPageProductId)||o.setCurrentDynamicPageProductId(((T=o.productsSeo[0])==null?void 0:T.id)||-1)),l.value=!1,await $e(),i.value=!1},openProductsAddInIframe:async()=>{u({isOpen:!0,path:lo.PRODUCTS_ADD})},openPaymentsInIframe:async()=>{u({isOpen:!0,path:lo.PAYMENT_MANAGEMENT})},openCompanyInformationInIframe:async()=>{u({isOpen:!0,path:lo.COMPANY_INFORMATION})},openShippingEditInIframe:async({shouldEditFirst:E})=>{u({isOpen:!0,path:lo.SHIPPING_EDIT,params:{shouldEditFirst:E}})},isEcommerceDataBeingUpdatedAfterChangesInAdmin:i}}),$a=Wo(en.GAMIFICATION,()=>{const t=C(),e=C([]),o=C(!1),n=C(),s=C(),a=Bt(),l=Yg(),i=c(()=>e.value.filter(({isCompleted:k})=>k).length),r=c(()=>{if(l.isMobileScreen||!s.value)return!1;const k=Math.floor(new Date(s.value).getTime()/1e3);return a.siteMeta.template===F5?k>eP:k>tP});return{ws:t,achievements:e,isGamificationLoaded:o,lastCompletedAchievement:n,createdAt:s,completedAchievementsCount:i,setWebsocketObject:k=>{if(k instanceof WebSocket){t.value=k;return}t.value=void 0},setAchievements:k=>{e.value=k},setIsGamificationLoaded:k=>{o.value=k},setLastCompletedAchievement:k=>{n.value=k},setCreatedAt:k=>{s.value=k},isGamificationAvailableForSite:r}}),uR="getAchievements",pR="completeAchievement",gR=1e3,mR=["h1","h2","h3","h4","h5","h6"],hR=[cl,Ri],Ho=()=>{const t=Gs(),{dispatch:e,state:o,getters:n}=nt(),s=Pn(),{setHighlightedElement:a,showOverlay:l}=tm(),{endOnboarding:i}=Uc(),{redirectToHPanelAddDomain:r,redirectToHPanelDomainSettings:u}=qo(),{t:p}=_t(),{openProductsAddInIframe:g,openPaymentsInIframe:b,openCompanyInformationInIframe:y,openShippingEditInIframe:k}=Fn(),I=$a(),E=me(),T=c(()=>n["ecommerce/isSiteWithEcommerceItems"]),P=c(()=>I.achievements.filter(({id:yt})=>hR.includes(yt))),z=c(()=>I.achievements.filter(({id:yt,type:At})=>![cl,Ri].includes(yt)&&At!==Rb.ECOMMERCE)),L=c(()=>{var At;return T.value?((At=I.achievements)==null?void 0:At.filter(({type:mt})=>mt===Rb.ECOMMERCE)).map(mt=>mt.id===Zd?{...mt,isPendingCompletion:!mt.achievedAt&&E.isPaymentsConnectionPending}:mt):[]}),D=c(()=>L.value.filter(({isCompleted:yt})=>yt)),$=c(()=>D.value.length),A=c(()=>I.achievements.some(({id:yt})=>yt===ba)),M=c(()=>z.value.filter(({isCompleted:yt})=>yt)),U=c(()=>I.lastCompletedAchievement),Y=c(()=>M.value.length),F=c(()=>{var yt;return((yt=z.value)==null?void 0:yt.length)>0&&z.value.length===Y.value}),W=c(()=>I.isGamificationLoaded),V=c(()=>Object.keys(n.siteBlocks).find(yt=>n.siteBlocks[yt].slot===yg)),K=c(()=>o.websiteId),Z=yt=>`[data-popper-reference="${yt}"]`,N=yt=>Z2({html:yt,tagsToMatch:["p"]}),X=yt=>Z2({html:yt,tagsToMatch:mR}),et=yt=>{var At;return(At=I.achievements)==null?void 0:At.find(mt=>yt===mt.id)},pt=c(()=>{var yt;return!!((yt=et(ba))!=null&&yt.isCompleted)}),st=c(()=>{const yt=W.value&&!z.value.length;return I.isGamificationAvailableForSite&&!yt}),J=({elementType:yt})=>[...n.currentPage.blocks,...V.value?[V.value]:[]].flatMap(mt=>(n.siteBlocks[mt].components||[]).map(xt=>({id:xt,...n.siteElements[xt]}))).filter(mt=>n.siteElements[mt.id].type===yt),it=yt=>{const At=document.querySelector(yt);At==null||At.scrollIntoView({block:"center"})},at=yt=>{e("updateCurrentBlockId",null),e("selectCurrentElement",{elementId:yt}),e("enterElementEditMode")},ot=c(()=>[{id:er},{id:qd,tooltipText:p("builder.gamificationHeadingEdited"),clickAction:()=>{const At=J({elementType:Po}).find(mt=>X(mt.content));if(!At){e(`gui/${Kn}`,{id:gs});return}it(`[data-element-ref="${At.id}"]`),at(At.id)}},{id:Ys,tooltipText:p("builder.gamificationImageUpdated"),clickAction:()=>{const[yt]=J({elementType:_n});if(yt){it(`[data-element-ref="${yt.id}"]`),at(yt.id);return}const mt=n.currentPage.blocks.map(Ct=>({id:Ct,...n.siteBlocks[Ct]})).find(Ct=>Ct.type===Us&&Ct.background.current==="image");if(!mt){e(`gui/${Kn}`,{id:gs});return}it(`[data-block-ref="${mt.id}"]`),e("updateCurrentBlockId",mt.id),e("setDefaultBlockEditTab","background"),e("enterBlockEditMode")}},{id:Yd,tooltipText:p("builder.gamificationParagraphEdited"),clickAction:()=>{const At=J({elementType:Po}).find(mt=>N(mt.content));if(!At){e(`gui/${Kn}`,{id:gs});return}it(`[data-element-ref="${At.id}"]`),at(At.id)}},{id:Ri,tooltipText:p("builder.gamificationLogoUpdated"),clickAction:()=>{var At;if(!(((At=n.siteBlocks.header)==null?void 0:At.type)===zr)||n.isNavHidden){e(`gui/${Kn}`,{id:Yi});return}it("#header"),e("updateCurrentBlockId","header"),e("setDefaultBlockEditTab",ec),e("enterBlockEditMode")}},{id:Ms,tooltipText:p("builder.gamificationSocialIconsChanged"),clickAction:()=>{const[yt]=J({elementType:Ni});if(!yt){e(`gui/${Kn}`,{id:gs});return}it(`[data-element-ref="${yt.id}"]`),at(yt.id)}},{id:Kd,tooltipText:p("builder.gamificationMobileChecked"),clickAction:()=>{const yt=Z(dc),At=document.querySelectorAll(yt)[1];a({element:At}),l(!0)}},{id:cl,tooltipText:p("builder.gamificationSeoUpdated"),clickAction:()=>{e("gui/OPEN_DRAWER",{id:fi})}},{id:ba,tooltipText:p("builder.gamificationDomainConnected"),clickAction:()=>{if(pt.value){u({currentDomain:s.customDomain,siteId:o.websiteId});return}r({currentDomain:s.customDomain,siteId:o.websiteId})}},{id:wr,tooltipText:p("builder.gamficationPublished"),clickAction:()=>{const yt=Z(ag);a({element:document.querySelector(yt)}),l(!0)}},{id:zp,clickAction:()=>g()},{id:Zd,clickAction:()=>b()},{id:Lp,clickAction:()=>y()},{id:$p,clickAction:()=>k({shouldEditFirst:1})}]),ft=()=>{if(!I.ws||I.ws.readyState!==1)throw new Error("Websocket doesn't exist or is not connected");const yt=JSON.stringify({method:uR});I.ws.send(yt)},tt=async yt=>{var xt;const At=!!((xt=et(yt))!=null&&xt.isCompleted),mt=!A.value&&yt===ba;if(!st.value||At||mt||(I.ws||await wt(K.value),!I.ws||I.ws.readyState!==1))return;const Ct=JSON.stringify({method:pR,slug:yt});try{I.ws.send(Ct),Et.logEvent({eventName:Qd.TASK_COMPLETED[yt]}),z.value.every(Gt=>Gt.id===yt||(Gt==null?void 0:Gt.isCompleted))&&Et.logEvent({eventName:Qd.COMPLETED})}catch(Ht){e("notifications/notify",{messageI18nKeyPath:"builder.gamificatioFailedError"}),jt(Ht)}},gt=async()=>{F.value||(I.setWebsocketObject(),await new Promise(yt=>{window.setTimeout(yt,gR)}),wt(K.value))},Q=async yt=>{var At;if(!yt.data||yt.data==="JWT verification failed"){I.setIsGamificationLoaded(!0),bt();return}try{const mt=JSON.parse(yt.data.toString());if(!(mt!=null&&mt.achievements)){bt();return}const Ct=[...z.value],xt=new Date(mt.created_at).getTime(),Gt=Object.entries(mt.achievements).filter(([ae])=>ot.value.find(ht=>ht.id===ae)).map(([ae,ht])=>{const $t=ot.value.find(kt=>kt.id===ae);return{id:ae,drawerNote:$t!=null&&$t.drawerNote?p($t==null?void 0:$t.drawerNote):"",isCompleted:!!ht.achieved_at,achievedAt:ht.achieved_at,name:p(oP[ae]),clickAction:$t==null?void 0:$t.clickAction,tooltipText:$t==null?void 0:$t.tooltipText,type:ht.product}});I.setAchievements(Gt),I.setIsGamificationLoaded(!0),I.setCreatedAt(xt);const Lt=ae=>Ct.some(ht=>ae.id===ht.id&&(ae==null?void 0:ae.isCompleted)!==(ht==null?void 0:ht.isCompleted)),Tt=z.value.find(ae=>Lt(ae));Tt&&I.setLastCompletedAchievement(Tt),!!!((At=et(er))!=null&&At.isCompleted)&&st.value&&(i(),tt(er))}catch(mt){String(mt).includes("jwt expired")&&(await t.refreshToken(""),bt(),wt(K.value))}},bt=()=>{if(I.ws)try{I.ws.close(),I.setWebsocketObject()}catch(yt){e("notifications/notify",{messageI18nKeyPath:"builder.gamificatioFailedError"}),jt(yt)}},wt=async yt=>{if(!I.isGamificationAvailableForSite){I.setIsGamificationLoaded(!0);return}if(!(!yt||I.ws))try{const At=await dR({url:`wss://gamification-prod.hostinger.io/gamification?sso_token=${Ac()}&site_id=${yt}`,onMessage:Q,onClose:gt,enableRepeatMessageProtection:!0});I.setWebsocketObject(At),z.value.length||ft()}catch(At){jt(At),I.setIsGamificationLoaded(!0),e("notifications/notify",{messageI18nKeyPath:"builder.gamificationFailedErrorV2"})}};return Rt(F,yt=>{yt&&bt()}),{achievements:z,otherTips:P,completedAchievementsCount:Y,areAllAchievementsCompleted:F,connectToWebsocket:wt,closeWebsocketConnection:bt,completeAchievement:tt,achievementData:ot,isParagraphElement:N,isHeadingElement:X,handleMessageEvent:Q,isGamificationVisible:st,lastCompletedAchievement:U,getAchievementById:et,ecommerceTips:L,completedEcommerceTips:D,completedEcommerceTipsCount:$}},Ry="https://builder-backend.hostinger.com/v3/sites/assets",bR=async t=>{const{data:e}=await Ut.get(`${Ry}/${t}`);return e},fR=async(t,e)=>Ut.delete(Ry,{data:{assets:t,siteId:e}}),yR=(t,e)=>{const o=new FormData;return o.append("font",t),o.append("siteId",e),Ut.post("https://builder-backend.hostinger.com/v3/sites/assets/fonts",o,{headers:{"Content-Type":"multipart/form-data"}})},vR=({siteId:t,assetsData:e={}})=>Ut.post(`${Ry}/${t}/assets-data`,{assetsData:e}),My=({directory:t,assetPaths:e,assets:o,includeFromSubfolders:n=!1})=>Object.entries(e).filter(([,s])=>{var r;const a=s.path.startsWith(t);if(n)return a;if(!a)return!1;const l=(r=s.path.split(t)[1])==null?void 0:r.match($9),i=s.path.match(z9);return l||i}).map(([s,a])=>({...o.find(({url:i})=>i.split("/").slice(-1)[0]===s),...a})),_R=({assetsData:t})=>{const e=Object.values(t).flatMap(s=>{const a=s.path.lastIndexOf("/");return s.path.slice(0,a).split("/").filter(i=>i).map((i,r,u)=>`/${u.slice(0,r+1).join("/")}/`)});return[...new Set(e)].map(s=>{const a=s.split("/").filter(i=>i!==""),l=a.slice(0,-1).join("/");return{path:s,name:decodeURIComponent(a[a.length-1]),id:ie(),parentPath:l.length?`/${l}/`:"/"}}).sort((s,a)=>s.name.localeCompare(a.name))},wR=({directory:t,folders:e})=>e.filter(o=>o.parentPath===t),J2=t=>{const e=encodeURIComponent(t);return e.split(".").length===1?e:e.split(".").slice(0,-1).join(".")},t_=({assetsList:t,id:e})=>{var s;const o=(s=t.value.find(a=>a.id===e))==null?void 0:s.url,n=(o==null?void 0:o.split("/"))||[];return n[n.length-1]},V6=["jpg","jpeg","png","gif","svg","webp","wav","mp3","flac","ogg","mp4","avi","mov","wmv","flv","doc","docx","xls","xlsx","ppt","pptx","odt","odp","pdf","epub","txt","rtf"],Bo={IMAGE:"image",VIDEO:"video",AI_IMAGE:"aiImage",DOCUMENT:"document"},cc=[Bo.IMAGE,Bo.DOCUMENT],Oo={MY_LIBRARY:"myLibrary",MY_LIBRARY_PAYWALL:"myLibraryPaywall",IMAGES:"images",DOCUMENTS:"documents",UNSPLASH:"unsplash",PEXELS:"pexels",AI_IMAGES:"aiImages"},ho=C([]),e_=C(!1),Sh=C(!1),Eh=C([]),kR=C(null),Cu=C([]),Pu=C(0),o_=17,n_=t=>t*1024*1024,Hy=t=>t.category===Bo.DOCUMENT,cs=t=>[Bo.IMAGE,Bo.AI_IMAGE].includes(t.category),IR=t=>Hy(t)?n_(qb):cs(t)?n_(Yb):0,Ny=(t,e=!1)=>{if(!t)return"";const o=Ia(t),n=o.indexOf("."),s=n>=0?n:o.length,a=s>o_?s-o_:s,l=o.slice(a,s),i=o.replace(l,""),r=i.split(".");if(r.length===1)return i;const p=r.slice(0,r.length-1).join(".");return e?`${p}.${En(i)}`:p},Ss=(t,e)=>{const o=Bt(),n=$a(),s=C(!1),{state:a,dispatch:l,getters:i}=nt(),{completeAchievement:r,isGamificationVisible:u}=Ho(),{notify:p}=Le(),g=c(()=>i["assets/currentDirectory"]),b=c(()=>My({directory:g.value,assets:ho.value,assetPaths:i["assets/assetPaths"]})),y=tt=>{const{file:gt,url:Q,isFetchedFromServer:bt,isBeingUploaded:wt,category:yt,lastModified:At}=tt;let mt=yt;if(!mt){const xt=En((gt?gt.name:Q)||"");mt=U0.includes(xt)?Bo.IMAGE:Bo.DOCUMENT}return{id:ie(),isFetchedFromServer:bt,url:Q,file:gt,isBeingUploaded:wt,isGalleryImageSelected:!1,isValid:!0,hasFailed:!1,transferProgress:0,category:mt,lastModified:At,initialDirectory:wt?g.value:null}},k=(tt,gt)=>{const Q=ho.value.findIndex(({id:bt})=>bt===tt);if(Q>-1){const bt=ho.value[Q];ho.value.splice(Q,1,{...bt,...gt})}else{const bt=y(gt);ho.value=[bt,...ho.value]}},I=c(()=>ho.value.filter(({hasFailed:tt})=>tt)),E=c(()=>ho.value.filter(({isBeingUploaded:tt})=>tt)),T=c(()=>E.value.filter(({isValid:tt})=>tt)),P=c(()=>E.value.filter(({isValid:tt})=>!tt)),z=()=>{Se({category:"useAssets.js",message:"removeInvalidAssetsBeingUploaded"});const tt=P.value.map(({id:gt})=>gt);ho.value=ho.value.filter(({id:gt})=>!tt.includes(gt))},L=tt=>{var gt,Q;k(tt.id,{height:((gt=tt.loadedImage)==null?void 0:gt.originalHeight)||null,width:((Q=tt.loadedImage)==null?void 0:Q.originalWidth)||null,galleryId:(t==null?void 0:t.galleryId)||null,name:tt.file.name,type:tt.file.type,lastModified:tt.file.lastModified,size:tt.file.size})},D=tt=>{if(En(tt.file.name)==="svg"||En(tt.file.name)==="ico"){const Q=new FileReader;Q.addEventListener("load",bt=>{k(tt.id,{urlBase64:bt.target.result})}),Q.readAsDataURL(tt.file);return}const gt=new FileReader;gt.addEventListener("load",Q=>{k(tt.id,{urlBase64:Q.target.result})}),qv.scale(tt.loadedImage.image,{maxWidth:1370}).toBlob(Q=>{gt.readAsDataURL(Q)})},$=tt=>{Se({category:"useAssets.js",message:"deleteAsset"}),ho.value=ho.value.filter(({id:gt})=>gt!==tt)},A=async(tt,gt)=>{var wt,yt;const Q=En(tt.file.name);if(!V6.includes(Q)){k(tt.id,{hasFailed:!0,isDimensionsTooLarge:!1,isUnsupportedFormat:!0});return}const bt=Ut.CancelToken.source();gt.append("siteId",a.websiteId),k(tt.id,{cancelSource:bt,hasFailed:!1});try{const At=cs(tt)?"https://builder-backend.hostinger.com/v3/sites/assets/images":"https://builder-backend.hostinger.com/v3/sites/assets/files",mt=await Ut.post(At,gt,{whitelistedStatusCodes:[413,415],cancelToken:bt.token,headers:{"Content-Type":"multipart/form-data"},onUploadProgress:xt=>{const Ht=Math.min((xt.loaded/tt.file.size).toFixed(2)*100,100);k(tt.id,{transferProgress:Ht})}});k(tt.id,{transferProgress:100,url:decodeURI(mt.data.url),isBeingUploaded:!1});const Ct=ho.value.find(({id:xt})=>xt===tt.id);return Cu.value=[...Cu.value,{...mt.data,initialDirectory:Ct.initialDirectory}],mt}catch(At){return jt(At),k(tt.id,{hasFailed:!0,isDimensionsTooLarge:((wt=At.response)==null?void 0:wt.status)===413,isUnsupportedFormat:((yt=At.response)==null?void 0:yt.status)===415}),{}}},M=()=>{Se({category:"useAssets.js",message:"deleteFailedAssets"}),ho.value=ho.value.filter(({hasFailed:tt})=>!tt)},U=()=>{try{T.value.forEach(tt=>{L(tt),cs(tt)&&D(tt);const gt=new FormData,Q=["svg","gif","webp"],bt=En(tt.file.name),wt=bt.includes(Q),yt=()=>bt.toLowerCase()==="jpg"?"jpeg":wt?"png":bt,At="image";if(!cs(tt)){gt.append("file",tt.file,tt.file.name),A(tt,gt);return}bt==="svg"?(gt.append(At,tt.file,tt.file.name),A(tt,gt)):tt.loadedImage.image.toBlob(mt=>{gt.append(At,wt||!tt.loadedImage.exif?tt.file:mt,tt.file.name),A(tt,gt)},`image/${yt()}`)})}catch(tt){jt(tt||new Error("Failed to upload assets"),{tags:{errorType:"Failed to upload assets"}})}finally{Pu.value=T.value.length}},Y=()=>{U(I.value)},F=()=>{s.value=!0},W=tt=>{tt.preventDefault(),s.value=!0},V=()=>{s.value=!1},K=async()=>{const tt=E.value.filter(bt=>cs(bt));(await Promise.allSettled(tt.map(async bt=>{try{return{...bt,loadedImage:await qv(bt.file,{canvas:!0,orientation:!0,meta:!0})}}catch{throw k(bt.id,{hasFailed:!0}),new Error("Failed to load image")}}))).filter(bt=>bt.status==="fulfilled").map(bt=>bt.value).forEach(({id:bt,loadedImage:wt})=>{k(bt,{loadedImage:wt})})},Z=tt=>{k(tt,{isValid:!1})},N=()=>{E.value.forEach(tt=>{const{id:gt,file:Q}=tt;if(Q.size>IR(tt)){Z(gt);return}ho.value.some(wt=>wt.lastModified===Q.lastModified&&wt.size===Q.size)&&Z(gt)})},X=async tt=>{var Q,bt;tt.preventDefault(),s.value=!1;const gt=((Q=tt==null?void 0:tt.dataTransfer)==null?void 0:Q.files)||((bt=tt==null?void 0:tt.target)==null?void 0:bt.files);gt&&([...gt].forEach(wt=>k(null,{file:wt,isFetchedFromServer:!1,isBeingUploaded:!0})),await K(),await N(),!P.value.length&&U())},et=async({file:tt})=>{k(null,{file:tt,isFetchedFromServer:!1,isBeingUploaded:!0}),await K(),await N();const gt=T.value[0],Q=En(gt.file.name);if(P.value.length||Q!=="svg")return{};const bt=new FormData;bt.append("image",gt.file,gt.file.name);const wt=await A(gt,bt);if(!wt.data)throw new Error("Failed to upload asset");return wt.data},pt=()=>{ho.value=ho.value.map(tt=>{const gt=b.value.some(Q=>Q.url===tt.url);return{...tt,isGalleryImageSelected:gt&&(cs(tt)||tt.isGalleryImageSelected)}})},st=()=>{ho.value=ho.value.map(tt=>({...tt,isGalleryImageSelected:!1}))},J=async()=>{Sh.value=!0;const tt=Eh.value.map(gt=>Ia(gt.url)).map(gt=>{var wt;const Q="generated";return((wt=gt.split("-"))==null?void 0:wt[0])===Q?`${Q}/${gt}`:gt});try{await fR(tt,a.websiteId),e_.value=!1,e==null||e.emit("close"),Eh.value.forEach(gt=>{const Q=gt.url.includes(i.headerBlock.settings.logoImagePath),bt=n.achievements.find(({id:wt})=>wt===Ri);u&&Q&&bt&&!bt.isCompleted&&r(Ri),$(gt.id)})}catch(gt){p({messageI18nKeyPath:"builder.errorWhileDeletingImage"}),jt(gt),console.error(gt)}finally{Sh.value=!1}},it=({asset:tt,newAltTag:gt})=>{const{url:Q}=tt,bt=(Q==null?void 0:Q.split("/"))||[],wt=bt[bt.length-1];Object.entries(o.site.languages).flatMap(([At,mt])=>{const{elements:Ct,blocks:xt}=mt;return Object.entries(xt).forEach(([Gt,{background:Lt}])=>{Lt.current===WT&&Lt.path===wt&&l("updateBlockData",{blockId:Gt,blockData:{background:{alt:gt}},merge:!0})}),Object.entries(Ct).filter(([,{type:Gt,settings:Lt,images:Tt}])=>Gt===_n?Lt.path===wt:Gt===zi?Tt.some(({path:Vt})=>Vt===wt):!1).map(([Gt,Lt])=>{const{settings:Tt,type:Vt,images:ae}=Lt;return Vt===_n?[Gt,At,{...Lt,settings:{...Tt,alt:gt}}]:Vt===zi?[Gt,At,{...Lt,images:ae.map(ht=>ht.path!==wt?ht:{...ht,alt:gt})}]:[Gt,At,Lt]})}).forEach(([At,mt,Ct])=>{l("mergeElementData",{elementId:At,elementData:Ct,locale:mt})})};Rt([()=>a.assets.hasInitialized,()=>a.assets.hasLoaded],([tt,gt])=>{if(!tt&>){const Q=a.assets.assets.map(bt=>y({...bt,url:decodeURI(bt.url),isFetchedFromServer:!0})).reverse();ho.value=Q,l("assets/initAssetManager")}},{immediate:!0}),Rt(Cu,tt=>{if(tt.length===0||tt.length!==Pu.value)return;const gt=tt.filter(Q=>Q.url);l("assets/addAssetsFolderData",{assets:gt}),Cu.value=[],Pu.value=0},{immediate:!0});const at=tt=>{const gt=ho.value.findIndex(({id:bt})=>bt===tt),Q=ho.value[gt];ho.value.splice(gt,1,{...Q,isGalleryImageSelected:!Q.isGalleryImageSelected})};let ot=null;const ft=tt=>{ot=tt,ot.addEventListener("dragenter",F),ot.addEventListener("dragover",W),ot.addEventListener("dragleave",V),ot.addEventListener("drop",X)};return so(()=>{ot&&(ot.removeEventListener("dragenter",F),ot.removeEventListener("dragover",W),ot.removeEventListener("dragleave",V),ot.removeEventListener("drop",X))}),{updateUsedImageAltTag:it,isAssetCategoryDocument:Hy,isAssetCategoryImage:cs,isDraggedOver:s,isDeleteAssetModalOpened:e_,isAssetBeingDeleted:Sh,listenForDragAndDrop:ft,onSelectFiles:X,deleteFailedAssets:M,deleteAsset:$,retryFailedAssets:Y,assets:ho,uploadAssets:U,uploadAsset:A,upsertAsset:k,getAssetNameFromUrl:Ny,invalidAssetsBeingUploaded:P,removeInvalidAssetsBeingUploaded:z,selectAllGalleryImages:pt,deselectSelectedGalleryImages:st,toggleGalleryImageCheckbox:at,hasServerAssetsLoaded:c(()=>a.assets.hasInitialized),uploadSvgAsset:et,deleteMediaAsset:J,assetsToDelete:Eh,folderToDelete:kR,uploadingAssetCount:Pu}},La="https://builder-backend.hostinger.com/billing",SR=async t=>{const{data:e}=await Ut.get(`${La}/subscriptions/site/${t}`);return e.subscription},ER=async()=>{const{data:t}=await Ut.get(`${La}/subscriptions`);return t},xR=async({siteId:t,subscriptionId:e})=>Ut.patch(`${La}/subscriptions/connect-site`,{siteId:t,subscriptionId:e}),TR=t=>Ut.get(`${La}/subscriptions/activate-plan`,{params:{"site-id":t}}),_f=async()=>(await Ut.get(`${La}/sites`,{whitelistedStatusCodes:[401]})).data,CR=()=>Ut.get(`${La}/estimates/credits`),PR=t=>Ut.post(`${La}/orders/credits/purchase`,t),BR=t=>Ut.post(`${La}/orders/credits/confirm`,{token:t}),AR="https://builder-backend.hostinger.com/v3/hostinger-integration/unused-domain",DR=async()=>{const{data:t}=await Ut.get(AR);return t.websiteDomain},U6="https://builder-backend.hostinger.com/v1/users",j6=async()=>{const{data:t}=await Ut.get(`${U6}/me`,{whitelistedStatusCodes:[401]});return t.user},zR=t=>Ut.patch(`${U6}/locale`,{locale:t});const i_="SET_UNUSED_HOSTINGER_DOMAIN",s_="SET_IS_AUTH_INITIATED",W6="DECREMENT_CREDITS",$R={namespaced:!0,state:{user:null,isAuthInitiated:!1,hostingerDomain:null},getters:{isZyroUser:t=>{var e;return/@(zyro|hostinger)\.com$/.test((e=t.user)==null?void 0:e.email)},isGoRobotsUser:t=>{var e,o;return(o=(e=t.user)==null?void 0:e.email)==null?void 0:o.includes(d1)},isPanelRegressionUser:t=>{var e,o;return(o=(e=t.user)==null?void 0:e.email)==null?void 0:o.includes(IC)},isGoRobotsFreePublishUser:t=>{var e;return(e=t.user)==null?void 0:e.email.includes(SC)},isHostingerRef:t=>{var e;return((e=t.user)==null?void 0:e.ref)===wC},isUserAllowedToPublish:(t,e,o,n)=>e.isZyroUser||e.isGoRobotsFreePublishUser||n["subscription/hasActiveSubscription"],isAbleToConnectHostingerDomain:(t,e)=>!!(e.isHostingerRef&&t.hostingerDomain),getUserEmail:t=>{var e;return(e=t.user)==null?void 0:e.email},userId:t=>{var e;return(e=t.user)==null?void 0:e.id},userHpanelId:t=>{var e;return(e=t.user)==null?void 0:e.hPanelId}},mutations:{[s_]:(t,e)=>{t.isAuthInitiated=e},setUser:(t,e)=>{t.user=e},[i_]:(t,e)=>{t.hostingerDomain=e},[W6]:(t,e)=>{t.user={...t.user,credits:t.user.credits-e}}},actions:{getUser:async({state:t,commit:e,getters:o},n)=>{var i;const s=Bt(),a=nn(),l=fo();if(!(t.isAuthInitiated&&!(n!=null&&n.force))){e(s_,!0);try{const r=await j6();if(!r)return;(i=r.email)!=null&&i.includes(d1)&&(s.setSiteMetaData({key:"qa",value:!0}),await l.saveWebsite()),e("setUser",r),a.setUser({userData:r}),Et.initAmplitude({userId:o==null?void 0:o.userHpanelId});const u={id:r.id,hPanelId:o==null?void 0:o.userHpanelId,CRM:`https://crm.hostinger.io/client/${o==null?void 0:o.userHpanelId}`};E5(u),Bx(u)}catch(r){jt(r)}}},setHostingerDomain:async({commit:t,getters:e})=>{if(!e.isHostingerRef)return;const o=await DR();t(i_,o)}}},LR=2e3,OR=20,Gy=()=>{const{state:t,dispatch:e,commit:o}=nt(),n=c(()=>t.user.user.credits),s=C(0),a=C(!1),l=()=>{localStorage.removeItem(rp),a.value=!1},i=async()=>{if(s.value>=OR){l();return}const u=localStorage.getItem(rp);if(!(!(new URLSearchParams(window.location.search).get("creditsPurchased")==="1")||!u))try{a.value=!0,await BR(u),await e("user/getUser",{force:!0}),localStorage.removeItem(rp),a.value=!1,e("notifications/notify",{theme:wc,headingI18nKeyPath:"builder.imageCreditsToasterHeader",messageI18nKeyPath:"builder.imageCreditsToasterMessage"}),Et.logEvent({eventName:"website_builder.ai_image_generator.payment_successful"})}catch(b){if(b.request.status!==402){l();return}setTimeout(async()=>{s.value+=1,await i()},LR)}};return{userCredits:n,isCreditsOrderCheckLoading:a,checkCreditsOrder:i,decrementUserCredits:({generateImageCount:u=Dp}={})=>o(`user/${W6}`,Math.round(qC*u))}},a_=C(null),jc=()=>({activeDrawerPageSettingsPopup:a_,setActiveDrawerPageSettingsPopup:({pageId:e,tab:o=vn.GENERAL})=>{a_.value={id:e,tab:o}}}),Bu=C(!1),l_=C(!1),xh=C(!1),wn=()=>{const{dispatch:t}=nt(),{isAiBuilderMode:e}=vo(),o=ii(),{activeDrawerPageSettingsPopup:n}=jc(),s=()=>{Bu.value=!Bu.value},a=()=>{xh.value=!0},l=()=>{xh.value=!1,t(`gui/${hs}`),o.currentRoute.value.name!==ps&&!e.value&&o.push({name:ps})};return{isSidebarOpen:Bu,isInnerSidebarOpen:xh,isSidebarBackdropVisible:l_,toggleSidebar:s,closeSidebar:()=>{Bu.value=!1,l_.value=!1,n.value=null,l()},openInnerSidebar:a,closeInnerSidebar:l}},Rl="square",r_=1024,d_=1024,RR="landscape",c_=1344,u_=768,Qn=C(!1),q6=()=>{const{decrementUserCredits:t}=Gy(),{completeAchievement:e}=Ho(),{notify:o}=Le(),{t:n}=_t(),{upsertAsset:s}=Ss(),{closeSidebar:a}=wn(),{state:l,dispatch:i,getters:r}=nt(),{defaultElements:u,addLayoutElement:p}=za(),{hoveredBlockId:g}=kl(),b=c(()=>r.siteElements),y=c(()=>r.siteBlocks),k=c(()=>r["gui/isMobileMode"]),I=c(()=>l.currentBlockId||g.value),E=c(()=>y.value[I.value]),{blockElements:T}=Vc({blockData:E,siteElements:b,shouldBuildResponsive:!1}),P="https://support.hostinger.com/en/articles/8670801-website-builder-guidelines-for-ai-image-generation",z=C([]),L=C(!1),D=[{name:n("builder.aiImageGenerationStyleEnhance"),file:"/images/image-generator-styles/enhance.png",value:"enhance"},{name:n("builder.aiImageGenerationStyleAnime"),file:"/images/image-generator-styles/anime.png",value:"anime"},{name:n("builder.aiImageGenerationStyleDigitalArt"),file:"/images/image-generator-styles/digital-art.png",value:"digital-art"},{name:n("builder.aiImageGenerationStyleComicBook"),file:"/images/image-generator-styles/comic-book.png",value:"comic-book"},{name:n("builder.aiImageGenerationStyleFantasyArt"),file:"/images/image-generator-styles/fantasy-art.png",value:"fantasy-art"},{name:n("builder.aiImageGenerationStyleAnalogFilm"),file:"/images/image-generator-styles/analog-film.png",value:"analog-film"},{name:n("builder.aiImageGenerationStyleNeonPunk"),file:"/images/image-generator-styles/neon-punk.png",value:"neon-punk"},{name:n("builder.aiImageGenerationStyleIsometric"),file:"/images/image-generator-styles/isometric.png",value:"isometric"},{name:n("builder.aiImageGenerationStyleLowPoly"),file:"/images/image-generator-styles/low-poly.png",value:"low-poly"},{name:n("builder.aiImageGenerationStyleOrigami"),file:"/images/image-generator-styles/origami.png",value:"origami"},{name:n("builder.aiImageGenerationStyleLineArt"),file:"/images/image-generator-styles/line-art.png",value:"line-art"},{name:n("builder.aiImageGenerationStyleCraftClay"),file:"/images/image-generator-styles/craft-clay.png",value:"modeling-compound"},{name:n("builder.aiImageGenerationStyleCinematic"),file:"/images/image-generator-styles/cinematic.png",value:"cinematic"},{name:n("builder.aiImageGenerationStyle3DModel"),file:"/images/image-generator-styles/3d-model.png",value:"3d-model"},{name:n("builder.aiImageGenerationStylePixelArt"),file:"/images/image-generator-styles/pixel-art.png",value:"pixel-art"}],$=C(Rl),A=()=>{z.value=[],L.value=!1},M=async({description:K,shouldAddImageElement:Z=!1,imageCount:N=Dp})=>{var st,J;L.value=!0,$.value=l.currentElementId||Z?Rl:RR;const X=$.value===Rl?r_:c_,et=$.value===Rl?d_:u_,pt=()=>o({headingI18nKeyPath:"builder.invalidAiImageDescription",messageI18nKeyPath:"builder.aiImageDescriptionIncludesBadWords",isDiscardButtonShown:!1,submitLabelI18nKeyPath:"common.learnMore",submitCallback:()=>{window.open(P,"_blank")}});try{const{data:it}=await oR({description:K,width:X,height:et,siteId:l.websiteId,count:N});if(!it.images.length){pt(),A();return}it.images.forEach(ot=>{const ft=`/${ot.name}`;i("assets/setAssets",[...l.assets.assets,{...ot,name:ot.name,path:ft}]),s(null,{...ot,url:decodeURI(ot.url),isFetchedFromServer:!0,name:ot.name,path:ft}),z.value.push(ot.url)}),i("assets/addAssetsFolderData",{assets:l.assets.assets}),t({generateImageCount:it.images.length})}catch(it){if(console.error(it),L.value=!1,((st=it.response)==null?void 0:st.status)===451){pt();return}if(((J=it.response)==null?void 0:J.status)===429){o({message:n("builder.aiImageGenerationDailyLimit")});return}o({message:n("builder.aiImageGenerationFailedGeneration")}),jt(it)}L.value=!1},U=K=>{const{origin:Z}=new URL(K);return{fullResolutionWidth:$.value===Rl?r_:c_,fullResolutionHeight:$.value===Rl?d_:u_,settings:{path:K,origin:Z}}},Y=async K=>{var st;const Z=u.value.image,N=U(K),X={...Z.content,...N,settings:{...Z.content.settings,...N.settings,styles:{...((st=Z.content.settings)==null?void 0:st.styles)||{}}}},et=document.querySelector(`[data-block-ref='${I.value}'`),pt={newElementRawTop:IA,newElementRawWidth:k.value?mu.MOBILE:mu.DESKTOP,newElementRawHeight:k.value?mu.MOBILE:mu.DESKTOP};await p({blockElements:T.value,blockId:I.value,blockToAddRef:et,elementId:ie(),newElementData:X,newElementRawPosition:pt})},F=K=>{i("mergeCurrentElementData",{elementData:U(K)}),i("undoRedo/createSnapshot"),e(Ys)},W=K=>{const{origin:Z}=new URL(K),N={image:K,origin:Z,path:K,current:"image",color:null,alt:null};i("updateBlockData",{blockId:l.currentBlockId,blockData:{background:N},merge:!0}),i("undoRedo/createSnapshot"),e(Ys)};return{isGeneratingImages:L,generateImages:M,updateImage:async({shouldAddImageElement:K=!1,imageSrc:Z})=>{if(Z){if(K){if(!E.value){o({messageI18nKeyPath:"builder.aiImageCannotBeAddedToCurrentSectionError"}),a();return}if(E.value.type===Us){Y(Z),a();return}const N=x9({imageData:U(Z)});i("addBlock",{pageId:l.currentPageId,blockData:N.blockData,elements:N.elements,previousBlockId:I.value}),a();return}if(!(!l.currentElementId&&!l.currentBlockId)){if(l.currentElementId){F(Z);return}l.currentBlockId&&W(Z)}}},generatedImageSrcList:z,IMAGE_GENERATOR_STYLES:D,resetImageGenerator:A,aiImageGenerateGuildArticleLink:P}},om=t=>t[Math.floor(Math.random()*t.length)],Y6=(t,e)=>{const o=[...t],n=o.indexOf(e),s=o[n],a=Math.max(0,n-1),l=o[a];return o[n]=l,o[a]=s,o},K6=(t,e)=>{const o=[...t],n=o.indexOf(e),s=o[n],a=Math.min(o.length-1,n+1),l=o[a];return o[n]=l,o[a]=s,o},MR=(t,e)=>{const o=[...t],[n]=o.splice(o.indexOf(e),1);return o.push(n),o},HR=(t,e)=>{const o=[...t],[n]=o.splice(o.indexOf(e),1);return o.unshift(n),o},p_=(t,e,o)=>o?MR(t,e):K6(t,e),g_=(t,e,o)=>o?HR(t,e):Y6(t,e),NR=(t,e)=>t.sort((o,n)=>Math.abs(e-o)-Math.abs(e-n))[0],m_=t=>Math.max(...t),h_=t=>Math.min(...t),GR=({array1:t,array2:e})=>t.length!==e.length?!1:t.every((o,n)=>o===e[n]),FR={key:0,class:"text-body-2"},VR=q({__name:"AiImageGenerationButton",emits:["toggle-ai-generate"],setup(t,{emit:e}){const{getters:o}=nt(),n=e,s=c(()=>o["gui/isMobileMode"]);return mn(()=>{Qn.value=!1}),(a,l)=>{const i=ct("qa");return d(),S(mo,{class:"generate-image-button"},{default:_(()=>[O((d(),S(ut,{"button-type":"text",onClick:l[0]||(l[0]=r=>n("toggle-ai-generate"))},{icon:_(()=>[h(lt,{name:"auto_awesome"})]),default:_(()=>[s.value?B("",!0):(d(),v("span",FR,w(a.$t("builder.aiImageGenerationGenerateImage")),1))]),_:1})),[[i,"generate-image-button"]])]),_:1})}}}),Z6=H(VR,[["__scopeId","data-v-14f15868"]]),UR={class:"block-edit-controls"},jR={key:0,class:"text-body-2"},WR={__name:"BlockEditControlsBar",props:{blockId:{type:String,required:!0},enterEditModeButtonTitle:{type:String,required:!0},targetRef:{type:HTMLElement,default:null},isDuplicateButtonVisible:{type:Boolean,default:!1},isVisibilityButtonVisible:{type:Boolean,default:!1},isDeleteButtonVisible:{type:Boolean,default:!1},showDeleteWarning:{type:Boolean,default:!1},isReorderingButtonVisible:{type:Boolean,default:!1},isContextMenuButtonVisible:{type:Boolean,default:!0},isBlockWithElements:{type:Boolean,default:!1},isStretchToFullWidthButtonVisible:{type:Boolean,default:!1}},setup(t){const e=t,{getters:o,state:n,dispatch:s}=nt(),{hoveredBlock:a}=kl(),{selectedLayoutBlockId:l}=Sl(),{mousePositionX:i,mousePositionY:r,isContextMenuWithTriggerActive:u}=Il(),{isAiBuilderMode:p}=vo(),g=C(null),b=C(!1),y=Bt(),k=nn(),I=c(()=>n.gui.isMobileScreen),E=c(()=>o.isCurrentPagePrivate),T=c(()=>y.site),P=c(()=>o.siteBlocks),z=c(()=>o.siteElements),L=c(()=>o.currentPage),D=c(()=>L.value.blocks),$=c(()=>L.value.blocks.indexOf(e.blockId)),A=c(()=>P.value[e.blockId]),M=c(()=>e.isDeleteButtonVisible&&!I.value),U=c(()=>e.isVisibilityButtonVisible&&!I.value),Y=c(()=>n.currentLocale),F=c(()=>n.currentPageId),W=c(()=>{var tt;return((tt=A.value[ge])==null?void 0:tt.isHidden)??!1}),V=c(()=>{var tt;return((tt=A.value[se])==null?void 0:tt.isHidden)??!1}),K=c(()=>$.value!==0&&$.value!==-1),Z=c(()=>$.value!==D.value.length-1&&$.value!==-1),N=c(()=>A.value.type===Us&&!p.value),{blockElements:X}=e.isBlockWithElements?Vc({blockData:A,siteElements:z,shouldBuildResponsive:!1}):{},et=()=>{s("enterBlockEditMode"),s("leaveElementEditMode")},pt=()=>{s("leaveElementEditMode"),s("leaveBlockEditMode");const{newBlock:tt,newElements:gt,newBlocks:Q}=Nr({siteData:T.value,blockId:e.blockId,fromLocale:E.value?Kt:Y.value});s("addBlock",{pageId:F.value,blockData:tt,blocks:Q,elements:gt,previousBlockId:e.blockId}),Se({category:"CLICK:Duplicate section",data:{blockId:e.blockId,pageId:F.value}})},st=({isHidden:tt,positionKey:gt})=>{s("updateBlockData",{blockId:e.blockId,blockData:{[gt]:{isHidden:tt}},merge:!0})},J=({forceRemove:tt=!1}={})=>{e.showDeleteWarning&&!tt?b.value=!0:(s("leaveElementEditMode"),s("leaveBlockEditMode"),s("setDefaultBlockEditTab",""),Se({category:"CLICK:Remove section",data:{blockId:e.blockId}}),s("removeBlock",{blockId:e.blockId}),a.value=null)},it=async({direction:tt})=>{const gt=tt==="up"?Y6(D.value,e.blockId):K6(D.value,e.blockId);s("mergePageData",{pageId:F.value,pageData:{blocks:gt}})},at=({location:tt}={})=>{Qn.value||Et.logEvent({eventName:"website_builder.ai_image_generator.enter",eventProperties:{location:`section-${tt}`}}),Qn.value=!Qn.value},ot=({isOpen:tt})=>{l.value=tt?e.blockId:null,u.value=tt,i.value=null,r.value=null},ft=()=>{s("updateBlockData",{blockId:e.blockId,blockData:{isFullWidth:!A.value.isFullWidth},merge:!0})};return mn(()=>{Qn.value=!1}),(tt,gt)=>{var bt;const Q=ct("qa");return d(),v(dt,null,[m("div",UR,[f(k).isAiTypeSelectionVisible?(d(),S(h8,{key:0,"block-id":t.blockId},null,8,["block-id"])):B("",!0),vt(tt.$slots,"prepend",{},void 0,!0),O((d(),S(ut,{"button-type":"plain",theme:"highlight",onClick:et},si({default:_(()=>[I.value?B("",!0):(d(),v("span",jR,w(t.enterEditModeButtonTitle),1))]),_:2},[I.value?{name:"icon",fn:_(()=>[h(lt,{name:"settings"})]),key:"0"}:void 0]),1024)),[[Q,"element-button-edit"]]),vt(tt.$slots,"default",{},void 0,!0),N.value&&f(ze)?(d(),v(dt,{key:1},[h(Vo),h(Z6,{onToggleAiGenerate:gt[0]||(gt[0]=wt=>at({location:"controls"}))})],64)):B("",!0),t.isDuplicateButtonVisible||U.value||M.value?(d(),S(Vo,{key:2})):B("",!0),t.isStretchToFullWidthButtonVisible?(d(),S(mo,{key:3,title:tt.$t("common.stretch")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",onClick:ft},{icon:_(()=>[h(lt,{name:"width",color:A.value.isFullWidth?"primary":"dark",class:rt({"block-edit-controls__icon--setting-enabled":A.value.isFullWidth})},null,8,["color","class"])]),_:1})),[[Q,"builder-section-btn-stretch"]])]),_:1},8,["title"])):B("",!0),t.isStretchToFullWidthButtonVisible?(d(),S(Vo,{key:4})):B("",!0),t.isDuplicateButtonVisible?(d(),S(mo,{key:5,title:tt.$t("common.duplicate")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",title:tt.$t("common.duplicate"),onClick:pt},{icon:_(()=>[h(lt,{name:"content_copy"})]),_:1},8,["title"])),[[Q,"builder-sectionedit-buttonduplicate"]])]),_:1},8,["title"])):B("",!0),U.value?O((d(),S(mo,{key:6,title:tt.$t("builder.editBlockButton.hideShow")},{default:_(()=>[h(b8,{class:"edit-actions__button","is-hidden-desktop":W.value,"is-hidden-mobile":V.value,onSetDesktopVisibility:gt[1]||(gt[1]=wt=>st({isHidden:wt,positionKey:f(ge)})),onSetMobileVisibility:gt[2]||(gt[2]=wt=>st({isHidden:wt,positionKey:f(se)}))},null,8,["is-hidden-desktop","is-hidden-mobile"])]),_:1},8,["title"])),[[Q,"builder-sectionedit-visibility"]]):B("",!0),M.value?(d(),S(mo,{key:7,title:tt.$t("common.delete")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",title:tt.$t("common.delete"),onClick:J},{icon:_(()=>[h(lt,{name:"delete"})]),_:1},8,["title"])),[[Q,"builder-sectionedit-buttondelete"]])]),_:1},8,["title"])):B("",!0),t.isReorderingButtonVisible?(d(),v(dt,{key:8},[h(Vo),h(mo,{title:tt.$t("builder.editBlockButton.moveUp")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",title:tt.$t("builder.editBlockButton.moveSectionUp"),disabled:!K.value,onClick:gt[3]||(gt[3]=wt=>it({direction:"up"}))},{icon:_(()=>[h(lt,{name:"arrow_upward"})]),_:1},8,["title","disabled"])),[[Q,"builder-section-btn-moveup"]])]),_:1},8,["title"]),h(mo,{title:tt.$t("builder.editBlockButton.moveDown")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",title:tt.$t("builder.editBlockButton.moveSectionDown"),disabled:!Z.value,onClick:gt[4]||(gt[4]=wt=>it({direction:"down"}))},{icon:_(()=>[h(lt,{name:"arrow_downward"})]),_:1},8,["title","disabled"])),[[Q,"builder-section-btn-movedown"]])]),_:1},8,["title"])],64)):B("",!0),t.isContextMenuButtonVisible?(d(),S(mo,{key:9,title:tt.$t("common.more")},{default:_(()=>[h(Vo),O((d(),S(ut,{ref_key:"contextMenuButtonRef",ref:g,"button-type":"plain",theme:"highlight",title:tt.$t("builder.contextMenuTitle"),onClick:gt[5]||(gt[5]=wt=>ot({isOpen:!f(u)}))},{icon:_(()=>[h(lt,{name:"more_vert"})]),_:1},8,["title"])),[[Q,"builder-sectionedit-buttoncontextmenu"]])]),_:1},8,["title"])):B("",!0)]),b.value?(d(),S(Ee,{key:0,to:"body"},[h(tn,{title:tt.$t("builder.editBlockButton.deleteLinkedSection"),"primary-button-text":tt.$t("common.cancel"),"secondary-button-text":tt.$t("common.delete"),"secondary-button-color":"danger",onClickPrimary:gt[6]||(gt[6]=wt=>b.value=!1),onClickSecondary:gt[7]||(gt[7]=wt=>J({forceRemove:!0})),onClose:gt[8]||(gt[8]=wt=>b.value=!1)},{default:_(()=>[j(w(tt.$t("builder.editBlockButton.removeWarningText")),1)]),_:1},8,["title","primary-button-text","secondary-button-text"])])):B("",!0),f(u)?(d(),S(N6,{key:1,"is-enabled":"","block-elements":f(X),"block-id":t.blockId,"trigger-ref":(bt=g.value)==null?void 0:bt.$el,"is-mobile-copy-paste-allowed":t.isBlockWithElements,onDeleteBlock:J,onCloseContextMenu:gt[9]||(gt[9]=wt=>ot({isOpen:!1}))},null,8,["block-elements","block-id","trigger-ref","is-mobile-copy-paste-allowed"])):B("",!0)],64)}}},b_=H(WR,[["__scopeId","data-v-264c30d8"]]),qR={placement:"right-start",placementMobile:"right-start",flip:!1,offset:{mainAxis:24,crossAxis:24},offsetMobile:{mainAxis:24,crossAxis:0},autoUpdate:!0,padding:24},YR={placement:"right-start",placementMobile:"top",flip:!1,offset:{mainAxis:24,crossAxis:24},offsetMobile:{mainAxis:24,crossAxis:0},autoUpdate:!0,padding:24},KR={},ZR=Object.assign(KR,{__name:"BlockEditControls",props:{blockId:{type:String,required:!0},targetRef:{type:HTMLElement,default:null},enterEditModeButtonTitle:{type:String,default:""},isDuplicateButtonVisible:{type:Boolean,default:!1},isVisibilityButtonVisible:{type:Boolean,default:!1},isDeleteButtonVisible:{type:Boolean,default:!1},showDeleteWarning:{type:Boolean,default:!1},isReorderingButtonVisible:{type:Boolean,default:!1},isContextMenuButtonVisible:{type:Boolean,default:!0},isBlockWithElements:{type:Boolean,default:!1},editPopupOptions:{type:Object,default:()=>qR},controlsBarPopupOptions:{type:Object,default:()=>YR},isBlockNonGridElementActive:{type:Boolean,default:!1},isStretchToFullWidthButtonVisible:{type:Boolean,default:!1}},setup(t){const e=t,{state:o,getters:n,dispatch:s}=nt(),a=c(()=>o.gui.isMobileScreen),l=c(()=>n["gui/isMobileMode"]),i=c(()=>o.currentBlockId),r=c(()=>o.currentElementId),u=c(()=>Fs.value&&Wi.value===e.blockId),p=c(()=>i.value===e.blockId),g=c(()=>e.isBlockWithElements?p.value&&!r.value&&!u.value:p.value&&!e.isBlockNonGridElementActive&&!u.value),b=c(()=>o.isBlockEditorOpen),y=c(()=>l.value?e.controlsBarPopupOptions.placementMobile:e.controlsBarPopupOptions.placement),k=c(()=>l.value?e.controlsBarPopupOptions.offsetMobile:e.controlsBarPopupOptions.offset),I=c(()=>l.value?e.editPopupOptions.placementMobile:e.editPopupOptions.placement),E=T=>{He(T)===ce.Escape&&s("leaveBlockEditMode")};return Nt(()=>{window.addEventListener("keydown",E)}),so(()=>{window.removeEventListener("keydown",E)}),(T,P)=>g.value?(d(),S(Ee,{key:0,to:"body"},[b.value&&t.targetRef?(d(),S(ve,{key:0,"target-ref":t.targetRef,"portal-selector":f(So),placement:I.value,"auto-update":t.editPopupOptions.autoUpdate,offset:t.editPopupOptions.offset,flip:t.editPopupOptions.flip,padding:t.editPopupOptions.padding,class:"block-edit-controls__popup","is-mobile-fixed-to-bottom":""},{default:_(()=>[vt(T.$slots,"edit-mode-popup",{},void 0,!0)]),_:3},8,["target-ref","portal-selector","placement","auto-update","offset","flip","padding"])):a.value?(d(),S(Ee,{key:1,to:f(r3)},[h(b_,{"block-id":t.blockId,"enter-edit-mode-button-title":t.enterEditModeButtonTitle,"is-duplicate-button-visible":t.isDuplicateButtonVisible,"is-visibility-button-visible":t.isVisibilityButtonVisible,"is-delete-button-visible":t.isDeleteButtonVisible,"show-delete-warning":t.showDeleteWarning,"is-reordering-button-visible":t.isReorderingButtonVisible,"is-context-menu-button-visible":t.isContextMenuButtonVisible,"is-stretch-to-full-width-button-visible":t.isStretchToFullWidthButtonVisible,"is-block-with-elements":t.isBlockWithElements,"target-ref":t.targetRef},{default:_(()=>[vt(T.$slots,"additional-edit-buttons",{},void 0,!0)]),_:3},8,["block-id","enter-edit-mode-button-title","is-duplicate-button-visible","is-visibility-button-visible","is-delete-button-visible","show-delete-warning","is-reordering-button-visible","is-context-menu-button-visible","is-stretch-to-full-width-button-visible","is-block-with-elements","target-ref"])],8,["to"])):(d(),S(ve,{key:2,"target-ref":t.targetRef,"portal-selector":f(So),placement:y.value,"auto-update":t.controlsBarPopupOptions.autoUpdate,offset:k.value,flip:t.controlsBarPopupOptions.flip,"is-controls":""},{default:_(()=>[h(b_,{"block-id":t.blockId,"enter-edit-mode-button-title":t.enterEditModeButtonTitle,"is-duplicate-button-visible":t.isDuplicateButtonVisible,"is-visibility-button-visible":t.isVisibilityButtonVisible,"is-delete-button-visible":t.isDeleteButtonVisible,"show-delete-warning":t.showDeleteWarning,"is-reordering-button-visible":t.isReorderingButtonVisible,"is-block-with-elements":t.isBlockWithElements,"is-context-menu-button-visible":t.isContextMenuButtonVisible,"is-stretch-to-full-width-button-visible":t.isStretchToFullWidthButtonVisible,"target-ref":t.targetRef},{prepend:_(()=>[vt(T.$slots,"additional-edit-buttons-prepend",{},void 0,!0)]),default:_(()=>[vt(T.$slots,"additional-edit-buttons",{},void 0,!0)]),_:3},8,["block-id","enter-edit-mode-button-title","is-duplicate-button-visible","is-visibility-button-visible","is-delete-button-visible","show-delete-warning","is-reordering-button-visible","is-block-with-elements","is-context-menu-button-visible","is-stretch-to-full-width-button-visible","target-ref"])]),_:3},8,["target-ref","portal-selector","placement","auto-update","offset","flip"]))])):B("",!0)}}),Oa=H(ZR,[["__scopeId","data-v-bffa1e65"]]),QR={class:"block__hidden-overlay"},XR={class:"text-body-1"},JR=q({__name:"BlockHidden",emits:["button-click"],setup(t){return(e,o)=>(d(),v("div",QR,[m("p",XR,w(e.$t("builder.thisSectionIsHidden")),1),h(ut,{class:"block__hidden-button",onClick:o[0]||(o[0]=n=>e.$emit("button-click"))},{"icon-left":_(()=>[h(lt,{name:"visibility"})]),default:_(()=>[j(" "+w(e.$t("builder.showSection")),1)]),_:1})]))}}),tM=H(JR,[["__scopeId","data-v-eba37713"]]),eM={class:"linked-block-controls"},oM={class:"linked-block-controls__toggles"},nM={class:"text-body-2"},iM={class:"text-body-2"},sM={class:"text-body-2"},aM=q({__name:"LinkedBlockControls",props:{targetRef:{type:HTMLElement,default:null}},setup(t){const{getters:e,state:o,dispatch:n}=nt(),s=c(()=>e.currentPage),a=c(()=>o.currentPageId),l=c(()=>e.sitePages),i=c(()=>s.value[pu]),r=c(()=>s.value.footerSlotIsHidden),u=C(null),p=C(!1),g=({onAllPages:b,hide:y})=>{if(b)Object.keys(l.value).forEach(k=>{n("mergePageData",{pageId:k,pageData:{[pu]:y}})});else{const k=!!s.value[pu];n("mergePageData",{pageId:a.value,pageData:{[pu]:!k}})}};return(b,y)=>{var I;const k=ct("qa");return d(),v("div",eM,[h(mo,{ref_key:"linkedBlockControls",ref:u,title:b.$t("common.hide")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",title:b.$t("common.hide"),onClick:y[0]||(y[0]=E=>p.value=!p.value)},{icon:_(()=>[h(lt,{name:"visibility"})]),_:1},8,["title"])),[[k,"builder-sectionedit-buttonlinked"]])]),_:1},8,["title"]),p.value?(d(),S(ve,{key:0,"target-ref":(I=u.value)==null?void 0:I.$el,placement:"bottom","auto-update":"",onClickOutside:y[4]||(y[4]=E=>p.value=!1)},{default:_(()=>[m("div",oM,[O((d(),S(ut,{"button-type":"plain",theme:"highlight",onClick:y[1]||(y[1]=E=>g({onAllPages:!1,hide:i.value}))},{"icon-left":_(()=>[h(lt,{name:i.value?"visibility":"visibility_off",dimensions:"20px"},null,8,["name"])]),default:_(()=>[m("span",nM,w(i.value?b.$t("builder.globalBlock.showOnSingle"):b.$t("builder.globalBlock.hideOnSingle")),1)]),_:1})),[[k,"builder-sectionedit-buttonlinked-toggle"]]),O((d(),S(ut,{"button-type":"plain",theme:"highlight",onClick:y[2]||(y[2]=E=>g({onAllPages:!0,hide:!0}))},{"icon-left":_(()=>[h(lt,{name:"visibility_off",dimensions:"20px"})]),default:_(()=>[m("span",iM,w(b.$t("builder.globalBlock.hideOnAll")),1)]),_:1})),[[k,"builder-sectionedit-buttonlinked-hideall"]]),O((d(),S(ut,{"button-type":"plain",theme:"highlight",onClick:y[3]||(y[3]=E=>g({onAllPages:!0,hide:!1}))},{"icon-left":_(()=>[h(lt,{name:"visibility",dimensions:"20px"})]),default:_(()=>[m("span",sM,w(b.$t("builder.globalBlock.showOnAll")),1)]),_:1})),[[k,"builder-sectionedit-buttonlinked-showall"]])])]),_:1},8,["target-ref"])):B("",!0),(d(),S(Ee,{to:t.targetRef},[r.value?(d(),S(tM,{key:0,onButtonClick:y[5]||(y[5]=E=>g({onAllPages:!1,hide:!0}))})):B("",!0)],8,["to"]))])}}}),lM=H(aM,[["__scopeId","data-v-409c2d2c"]]),rM=q({props:{outlineStyle:{type:String,default:"solid"},outlineColor:{type:String,default:"var(--color-azure-dark)"}},computed:{outlineCSSVars(){return{"--outline-style":this.outlineStyle,"--outline-color":this.outlineColor}}}});function dM(t,e,o,n,s,a){return d(),v("div",{class:"overlay-outline",style:ne(t.outlineCSSVars)},null,4)}const Q6=H(rM,[["render",dM],["__scopeId","data-v-42db7643"]]),cM={__name:"LayoutGuideLines",props:{columnCount:{type:Number,required:!0},isVisible:{type:Boolean,default:!0},blockHeight:{type:Number,required:!0},desktopBlockHeight:{type:Number,required:!0},mobileBlockHeight:{type:Number,required:!0},snapRowGap:{type:Number,required:!0},snapRowHeight:{type:Number,required:!0}},setup(t){const e=t,o=c(()=>Math.round(e.blockHeight/(e.snapRowHeight+e.snapRowGap))),n=c(()=>({"--column-count":e.columnCount,"--row-count":o.value,"--column-gap":`${Fb}px`,"--row-height":`${e.snapRowHeight}px`,"--row-gap":`${e.snapRowGap}px`}));return(s,a)=>(d(),v("div",{class:rt(["guides",{"guides--invisible":!t.isVisible}]),style:ne(n.value)},[(d(!0),v(dt,null,zt(t.columnCount,l=>(d(),v("div",{key:l,class:"guides__guide"},[(d(!0),v(dt,null,zt(o.value,i=>(d(),v("div",{key:i,class:"guides__guide__row"}))),128))]))),128))],6))}},Au={[Ro.ELEMENT_EDGE]:"solid",[Ro.ELEMENT_CENTER]:"dashed",[Ro.COLUMN]:"solid",[Ro.ROW]:"solid",[Ro.BLOCK_CENTER]:"dashed"},Du={[Ro.ELEMENT_EDGE]:"var(--color-azure-dark)",[Ro.ELEMENT_CENTER]:"var(--color-azure-dark)",[Ro.COLUMN]:"var(--color-azure-dark)",[Ro.ROW]:"var(--color-azure-dark)",[Ro.BLOCK_CENTER]:"var(--color-warning-dark)"},uM=q({props:{elementPosition:{type:Object,default:null},yPoints:{type:Array,default:null},xPoints:{type:Array,default:null}},computed:{yLines(){const{left:t,width:e}=this.elementPosition,o=t+e;return this.yPoints.map(n=>{const s=Math.min(t,n.left),a=Math.max(o,n.right);return Ro.ROW===n.type?{top:`${n.location}px`,left:0,height:"1px",style:Au[n.type],color:Du[n.type]}:{top:`${n.location}px`,left:`${s}px`,width:`${a-s}px`,style:Au[n.type],color:Du[n.type]}})},xLines(){const{top:t,height:e}=this.elementPosition,o=t+e;return this.xPoints.map(n=>{if([Ro.COLUMN,Ro.BLOCK_CENTER].includes(n.type))return{top:0,left:`${n.location}px`,height:"100%",style:Au[n.type],color:Du[n.type]};const s=Math.min(t,n.top),a=Math.max(o,n.bottom);return{top:`${s}px`,left:`${n.location}px`,height:`${a-s}px`,style:Au[n.type],color:Du[n.type]}})}}}),pM={class:"snapping-lines"};function gM(t,e,o,n,s,a){return d(),v("div",pM,[t.yLines?(d(!0),v(dt,{key:0},zt(t.yLines,(l,i)=>(d(),v("div",{key:`y-${i}`,class:"snapping-lines__line snapping-lines__line--horizontal",style:ne({"--top":l.top,"--left":l.left,"--width":l.width,"--line-style":l.style,"--line-color":l.color})},null,4))),128)):B("",!0),t.xLines?(d(!0),v(dt,{key:1},zt(t.xLines,(l,i)=>(d(),v("div",{key:`x-${i}`,class:"snapping-lines__line snapping-lines__line--vertical",style:ne({"--top":l.top,"--left":l.left,"--height":l.height,"--line-style":l.style,"--line-color":l.color})},null,4))),128)):B("",!0)])}const mM=H(uM,[["render",gM],["__scopeId","data-v-239ac8a2"]]),hM={__name:"HorizontalGuideline",props:{top:{type:Number,default:null}},setup(t){ue(n=>({"4e86ce04":o.value}));const e=t,o=c(()=>`${e.top}px`);return(n,s)=>(d(),v("div",{class:"horizontal-guideline",style:ne({"--top":t.top})},null,4))}},bM=H(hM,[["__scopeId","data-v-89887456"]]),Fy=q({props:{position:{type:Object,required:!0},isAreaSelected:{type:Boolean,default:!1},isDragging:{type:Boolean,default:!1}},setup(t){const e=C(!1),o=c(()=>`${t.position.left}px`),n=c(()=>`${t.position.top}px`),s=c(()=>`${t.position.width}px`),a=c(()=>`${t.position.height}px`);return{leftCSSVar:o,topCSSVar:n,widthCSSVar:s,heightCSSVar:a,isDragged:e}}}),f_=()=>{ue(t=>({"0cc6db7c":t.topCSSVar,"7a17487c":t.leftCSSVar,"33ff2fb3":t.widthCSSVar,"70b9b9bc":t.heightCSSVar}))},y_=Fy.setup;Fy.setup=y_?(t,e)=>(f_(),y_(t,e)):f_;function fM(t,e,o,n,s,a){return d(),v("div",{class:rt(["drag-box",{"drag-box--selected":t.isAreaSelected,"drag-box--dragging":t.isDragging}])},null,2)}const yM=H(Fy,[["render",fM],["__scopeId","data-v-02fdc01e"]]),vM={__name:"SpacingHandle",props:{elementData:{type:Object,required:!0}},setup(t){const e=t,{getters:o}=nt(),n=c(()=>o["gui/isMobileMode"]),s=c(()=>n.value?se:ge),a=c(()=>e.elementData[s.value].width(d(),v("button",{ref:"spacingHandle",class:rt(["spacing-handle",{"spacing-handle--outside-element-box":a.value}])},[h(lt,{class:"spacing-handle__icon",name:"vertical_align_bottom",dimensions:"16px"})],2))}},_M=H(vM,[["__scopeId","data-v-14cee75d"]]),wM=t=>{const{x:e}=x5(t),{pressed:o}=Ax({target:t}),{x:n}=Dx();Rt([()=>o.value,()=>n.value],([s,a],[,l])=>{if(s){const i=l-a;e.value+=i}})},kM={key:0,class:"zyro-tabs"},IM=["title","disabled","onClick"],SM=q({__name:"ZyroTabs",props:{tabs:{},currentTab:{}},emits:["update:current-tab"],setup(t){const e=C(null);return wM(e),(o,n)=>{const s=ct("qa");return o.currentTab?(d(),v("div",kM,[m("div",{ref_key:"el",ref:e,class:"zyro-tabs__list"},[(d(!0),v(dt,null,zt(o.tabs,a=>O((d(),v("button",{key:a.title,class:rt([{"zyro-tabs__tab--active":o.currentTab.title===a.title,"zyro-tabs__tab--disabled":a.isDisabled,"zyro-tabs__tab--indicator":a.hasIndicator},"zyro-tabs__tab text-bold-2"]),title:a.title,disabled:a.isDisabled,onClick:l=>o.$emit("update:current-tab",a)},[j(w(a.title),1)],10,IM)),[[s,`builder-tab-${a.title}`]])),128))],512)])):B("",!0)}}}),xl=H(SM,[["__scopeId","data-v-7df55d39"]]),EM=["draggable"],xM={key:0,class:"popup-card__title text-heading-1"},TM={class:"popup-card__close"},CM={key:0,class:"popup-card__label text-overline"},PM={class:"popup-card__content"},BM={key:2,ref:"popupFooter",class:"popup-card__footer"},AM={__name:"ZyroPopupCard",props:{title:{type:String,default:""},type:{type:String,default:"",validator:t=>["editor",""].includes(t)},showCloseButton:{type:Boolean,default:!0},showFooter:{type:Boolean,default:!1},tabs:{type:Array,default:()=>[]},currentTab:{type:Object,default:()=>{}},maxWidth:{type:String,default:"400px"},editorPopupWidth:{type:String,default:"360px"},saveBtnTitle:{type:String,default:null},isFullHeight:{type:Boolean,default:!1},isSelectAllowed:{type:Boolean,default:!1},label:{type:String,default:""}},emits:["close","save","update:current-tab"],setup(t){ue(p=>({"6be61711":t.maxWidth,58543316:t.editorPopupWidth,"405a7016":s.value}));const{state:e}=nt(),o=C(null),n=C(50),s=c(()=>`${n.value}vh`),a=c(()=>e.gui.isMobileScreen),l=p=>{p.dataTransfer.setDragImage(new Image,0,0)},i=p=>{const{top:g}=o.value.getBoundingClientRect(),b=n.value+Math.round((g-p)/window.innerHeight*100);b>0&&b<100&&(n.value=b)},r=p=>{const{clientY:g}=p;i(g)},u=p=>{p.preventDefault();const{clientY:g}=p.touches[0];i(g)};return(p,g)=>{const b=ct("qa");return d(),v("div",{class:rt(["popup-card",{"popup-card--editor":t.type==="editor","popup-card--full-height":t.isFullHeight,"popup-card--select-allowed":t.isSelectAllowed}])},[t.showCloseButton||t.title||t.tabs.length?(d(),v("div",{key:0,ref_key:"popupHead",ref:o,class:"popup-card__head",draggable:a.value,onTouchmove:u,onDragstart:l,onDrag:r},[t.title?(d(),v("h4",xM,[j(w(t.title)+" ",1),vt(p.$slots,"title-suffix",{},void 0,!0)])):B("",!0),m("div",TM,[t.label?(d(),v("span",CM,w(t.label),1)):B("",!0),t.showCloseButton?O((d(),S(ut,{key:1,"button-type":"plain",title:p.$t("common.close"),onClick:g[0]||(g[0]=y=>p.$emit("close"))},{icon:_(()=>[h(lt,{name:"close"})]),_:1},8,["title"])),[[b,"builder-popupcard-btn-close"]]):B("",!0)])],40,EM)):B("",!0),t.tabs.length?(d(),S(xl,{key:1,tabs:t.tabs,"current-tab":t.currentTab,"onUpdate:currentTab":g[1]||(g[1]=y=>p.$emit("update:current-tab",y))},null,8,["tabs","current-tab"])):B("",!0),m("div",PM,[vt(p.$slots,"default",{},void 0,!0)]),t.showFooter?(d(),v("div",BM,[f(Hi)(p.$slots.footer)?vt(p.$slots,"footer",{key:0},void 0,!0):(d(),v(dt,{key:1},[O((d(),S(ut,{"button-type":"text",onClick:g[2]||(g[2]=y=>p.$emit("close"))},{default:_(()=>[j(w(p.$t("common.cancel")),1)]),_:1})),[[b,"builder-popupcard-cancelbtn"]]),O((d(),S(ut,{onClick:g[3]||(g[3]=y=>p.$emit("save"))},{default:_(()=>[j(w(t.saveBtnTitle??p.$t("common.save")),1)]),_:1})),[[b,"builder-popupcard-savebtn"]])],64))],512)):B("",!0)],2)}}},zo=H(AM,[["__scopeId","data-v-8f938d38"]]),DM=q({setup(){return{hasSlotContent:Hi}}}),zM={class:"zyro-field-wrapper"},$M={key:0,class:"zyro-field-wrapper__prefix"},LM={key:1,class:"zyro-field-wrapper__suffix"};function OM(t,e,o,n,s,a){return d(),v("div",zM,[t.hasSlotContent(t.$slots.prefix)?(d(),v("span",$M,[vt(t.$slots,"prefix",{},void 0,!0)])):B("",!0),vt(t.$slots,"default",{},void 0,!0),t.hasSlotContent(t.$slots.suffix)?(d(),v("span",LM,[vt(t.$slots,"suffix",{},void 0,!0)])):B("",!0)])}const X6=H(DM,[["render",OM],["__scopeId","data-v-b9e2ebe4"]]),RM=q({props:{for:{type:String,default:""},theme:{type:String,default:"primary",validator:t=>["primary","secondary"].includes(t)}},computed:{forProp(){return this.for}}}),MM={class:"zyro-label"},HM=["for"];function NM(t,e,o,n,s,a){return d(),v("div",MM,[m("label",{for:t.forProp||void 0,class:"zyro-label__label text-bold-2"},[vt(t.$slots,"default",{},void 0,!0)],8,HM)])}const Xt=H(RM,[["render",NM],["__scopeId","data-v-69679c18"]]),GM=q({components:{ZyroSvgDeprecated:qt,ZyroTooltip:Mo},props:{infoText:{type:String,default:""},mode:{type:String,default:"dark"}}}),FM={class:"info__button"},VM={class:"info__content"},UM={class:"text-body-2"};function jM(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated"),i=G("ZyroTooltip");return d(),S(i,{position:"right",class:"info","content-position":"absolute","toggle-event":"hover",mode:t.mode},{trigger:_(()=>[m("button",FM,[h(l,{name:"help"})])]),default:_(()=>[m("div",VM,[m("p",UM,w(t.infoText),1)])]),_:1},8,["mode"])}const WM=H(GM,[["render",jM],["__scopeId","data-v-5fc3d2c0"]]),qM=q({components:{ZyroFieldWrapper:X6,ZyroInput:bs,ZyroLabel:Xt,ZyroInfo:WM},props:{id:{type:String,default:""},label:{type:String,default:""},message:{type:String,default:""},placeholder:{type:String,default:""},error:{type:[String,Boolean],default:""},modelValue:{type:String,required:!0},autofocus:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},labelTheme:{type:String,default:"primary"},infoText:{type:String,default:""},inputTheme:{type:String,default:"primary"},maxlength:{type:[String,Number],default:null},inputTag:{type:String,default:"input",validator:t=>["input","textarea"].includes(t)},type:{type:String,default:""},inputType:{type:String,default:"",validator:t=>["","number"].includes(t)},suffix:{type:String,default:null},focusOnMount:{type:Boolean,default:!1},padding:{type:String,default:""},isMessageAbsolute:{type:Boolean,default:!1},qaSelector:{type:String,default:"textfield-input"},color:{type:String,default:""}},emits:["update:model-value","input-blur","input-focus","keyup-enter"],setup(){return{hasSlotContent:Hi}}}),YM={class:"zyro-field-text"},KM={class:"zyro-field-text__label-wrapper"};function ZM(t,e,o,n,s,a){const l=G("ZyroLabel"),i=G("ZyroInfo"),r=G("ZyroInput"),u=G("ZyroFieldWrapper");return d(),v("div",YM,[m("div",KM,[t.label?(d(),S(l,{key:0,for:t.id,class:rt(["zyro-field-text__label",[`zyro-field-text__label--${t.labelTheme}`,{"zyro-field-text__label--disabled":t.disabled}]])},{default:_(()=>[j(w(t.label),1)]),_:1},8,["for","class"])):B("",!0),t.infoText?(d(),S(i,{key:1,"info-text":t.infoText},null,8,["info-text"])):B("",!0)]),vt(t.$slots,"sublabel",{},void 0,!0),h(u,{class:"zyro-field-text__field-wrapper"},{prefix:_(()=>[vt(t.$slots,"prefix",{},void 0,!0)]),suffix:_(()=>[vt(t.$slots,"suffix",{},void 0,!0)]),default:_(()=>[h(r,{"input-id":t.id,class:"zyro-field-text__input",disabled:t.disabled,theme:t.inputTheme,padding:t.padding,autofocus:t.autofocus,"input-type":t.inputType,type:t.type,placeholder:t.placeholder,suffix:t.suffix,error:t.error,color:t.color,maxlength:t.maxlength,"focus-on-mount":t.focusOnMount,"qa-selector":t.qaSelector,"model-value":t.modelValue,"onUpdate:modelValue":e[0]||(e[0]=p=>t.$emit("update:model-value",p)),onInputBlur:e[1]||(e[1]=p=>t.$emit("input-blur",p)),onInputFocus:e[2]||(e[2]=p=>t.$emit("input-focus",p)),onKeyupEnter:e[3]||(e[3]=p=>t.$emit("keyup-enter"))},null,8,["input-id","disabled","theme","padding","autofocus","input-type","type","placeholder","suffix","error","color","maxlength","focus-on-mount","qa-selector","model-value"])]),_:3}),t.message||t.error?(d(),v("div",{key:0,class:rt(["zyro-field-text__message",{"zyro-field-text__message--error":t.error,"zyro-field-text__message--absolute":t.isMessageAbsolute}]),"data-qa":"textfield-message"},[t.hasSlotContent(t.$slots.error)?B("",!0):(d(),v(dt,{key:0},[j(w(t.error?t.error:t.message),1)],64)),vt(t.$slots,"error",{},void 0,!0)],2)):B("",!0),vt(t.$slots,"message",{},void 0,!0)])}const Ge=H(qM,[["render",ZM],["__scopeId","data-v-029e6438"]]),QM=q({__name:"EditBlockTabAnchor",setup(t){const e=nt(),o=C(""),n=c(()=>`#${e.getters.currentBlock.htmlId||""}`),s=c(()=>{const i=e.getters.currentLanguageData.locale===e.getters.defaultLocale?null:e.getters.currentLanguageData.locale,r=e.getters.homePageId===e.state.currentPageId?null:e.getters.currentPage.slug,u=[i,r].filter(Boolean).join("/");return new URL(`${u}${n.value}`,e.getters.siteUrl).toString()}),a=i=>{const{htmlId:r}=L9(i);e.dispatch("updateBlockData",{blockId:e.state.currentBlockId,blockData:{htmlId:r},merge:!0})},l=()=>{e.dispatch("updateInternalHrefs",{oldHref:`/#${o.value}`,newHref:`/${n.value}`})};return Nt(()=>{o.value=e.getters.currentBlock.htmlId}),bl(()=>{e.dispatch("undoRedo/createSnapshot")}),(i,r)=>(d(),S(Ge,{label:i.$t("builder.editBlockTabAnchor.anchorName"),"model-value":n.value,message:i.$t("builder.editBlockTabAnchor.anchorUrlExample",[s.value]),"qa-selector":"grid-tabanchor-input-anchor","onUpdate:modelValue":a,onInputBlur:l},null,8,["label","model-value","message"]))}}),wf=(t,e,o)=>Math.min(Math.max(t,e),o),XM={class:"zyro-range__input-wrapper"},JM=["value","min","max","step","disabled"],tH=["min","max","step","disabled","value"],eH=["textContent"],oH=8,nH=q({__name:"ZyroRange",props:{min:{default:""},max:{default:""},step:{default:""},disabled:{type:Boolean},units:{default:"px"},modelValue:{default:0},hasNumberInput:{type:Boolean},isValueShown:{type:Boolean,default:!0},isWithIconControls:{type:Boolean}},emits:["update:model-value"],setup(t,{emit:e}){const o=t,n=e,s=C(),a=()=>{var g;(g=s.value)==null||g.focus()},l=c(()=>o.max&&o.min?(Number(o.max)-Number(o.min))/oH:o.step?Number(o.step):1),i=g=>{if(o.disabled)return;const b=wf(Number.parseFloat(`${g}`),Number.parseFloat(`${o.min}`),Number.parseFloat(`${o.max}`));n("update:model-value",b)},r=()=>{i(Number(o.modelValue)-l.value)},u=()=>{i(Number(o.modelValue)+l.value)},p=g=>{const b=g.target;if(o.hasNumberInput){const y=wf(Number.parseFloat(b.value||"0"),Number.parseInt(`${o.min}`,10),Number.parseInt(`${o.max}`,10));n("update:model-value",y);return}n("update:model-value",Number(b.value))};return(g,b)=>(d(),v("div",{class:rt(["zyro-range",{"zyro-range--disabled":g.disabled}])},[m("div",XM,[g.isWithIconControls?(d(),S(ut,{key:0,"button-type":"plain","is-disabled":g.disabled,class:"zyro-range__minus",onClick:r},{icon:_(()=>[h(lt,{name:"remove"})]),_:1},8,["is-disabled"])):B("",!0),m("input",{ref:"rangeInput",value:g.modelValue,min:g.min,max:g.max,step:g.step,disabled:g.disabled,type:"range",onInput:p},null,40,JM),g.isWithIconControls?(d(),S(ut,{key:1,"button-type":"plain","is-disabled":g.disabled,class:"zyro-range__plus",onClick:u},{icon:_(()=>[h(lt,{name:"add"})]),_:1},8,["is-disabled"])):B("",!0),g.hasNumberInput?(d(),v("input",{key:2,ref_key:"numberInput",ref:s,min:g.min,max:g.max,step:g.step,type:"number",disabled:g.disabled,autocomplete:"off",value:g.modelValue,class:"zyro-range__number-input",onBlur:p,onKeyup:Bi(p,["enter"]),onKeydown:[Bi(p,["up"]),Bi(p,["down"])],onFocus:a,onChange:p},null,40,tH)):g.isValueShown?(d(),v("span",{key:3,class:"zyro-range__value text-bold-2",textContent:w(`${g.modelValue} ${g.units}`)},null,8,eH)):B("",!0)])],2))}}),Jo=H(nH,[["__scopeId","data-v-b45d4458"]]),iH=q({__name:"ColorPickerButton",props:{isGradient:{type:Boolean},color:{default:Pi},gradient:{},size:{default:"md"}},setup(t){const e=t,o=c(()=>({[`color-picker-button--${e.size}`]:e.size})),n=c(()=>e.isGradient&&e.gradient?{background:Z0(e.gradient)}:{backgroundColor:e.color});return(s,a)=>{const l=ct("qa");return O((d(),v("button",{class:rt(["color-picker-button",o.value]),style:ne(n.value)},null,6)),[[l,"color-picker-btn"]])}}}),Wc=H(iH,[["__scopeId","data-v-a3910144"]]),v_=(t,e,o)=>{const n=e.split("."),{length:s}=n;return n.reduce((a,l,i)=>a[l]=i===s-1?o:a[l]||{},t),t},kf={0:{primary:{"border-radius":999,"background-color":"rgb(0, 0, 0)","background-color-hover":"rgb(29, 30, 32)","font-color":"rgb(255, 255, 255)"},secondary:{"border-radius":999,"background-color":"white","background-color-hover":"rgb(240, 240, 240)","font-color":"rgb(0, 0, 0)"}},1:{primary:{"border-radius":8,"background-color":"rgb(0, 0, 0)","background-color-hover":"rgb(29, 30, 32)","font-color":"rgb(255, 255, 255)"},secondary:{"border-radius":8,"background-color":"white","background-color-hover":"rgb(240, 240, 240)","font-color":"rgb(0, 0, 0)"}},2:{primary:{"border-radius":0,"background-color":"rgb(0, 0, 0)","background-color-hover":"rgb(29, 30, 32)","font-color":"rgb(255, 255, 255)"},secondary:{"border-radius":0,"background-color":"white","background-color-hover":"rgb(240, 240, 240)","font-color":"rgb(0, 0, 0)"}}},sH={GridTextBox:{path:"content"}},aH={BlockNavigation:{paths:["background.gradient"]},BlockLayout:{paths:["background.gradient"]},BlockEcommerceProduct:{paths:["background.gradient"]},BlockEcommerceProductList:{paths:["background.gradient"]},BlockBlogHeader:{paths:["background.gradient"]},BlockBlogList:{paths:["background.gradient"]},BlockImageSlideshow:{paths:["background.gradient"]}},lH={BlockNavigation:{paths:["background.color","navLinkTextColor","navLinkTextColorHover"]},BlockLayout:{paths:["background.color"]},BlockEcommerceProduct:{paths:["background.color","navigationArrowsColor","buttonStyle.grid-button-primary-color","buttonStyle.grid-button-primary-color-hover","buttonStyle.grid-button-primary-color-active","buttonStyle.grid-button-primary-background-color","buttonStyle.grid-button-primary-background-color-hover","buttonStyle.grid-button-primary-border-color","buttonStyle.grid-button-primary-border-color-active","buttonStyle.grid-button-primary-border-color-hover","buttonStyle.grid-button-secondary-color","buttonStyle.grid-button-secondary-color-hover","buttonStyle.grid-button-secondary-color-active","buttonStyle.grid-button-secondary-background-color","buttonStyle.grid-button-secondary-background-color-hover","buttonStyle.grid-button-secondary-border-color","buttonStyle.grid-button-secondary-border-color-active","buttonStyle.grid-button-secondary-border-color-hover","textColorVars.h1-color","textColorVars.h2-color","textColorVars.h3-color","textColorVars.h4-color","textColorVars.h5-color","textColorVars.h6-color","textColorVars.body-color","textColorVars.body-large-color"]},BlockEcommerceProductList:{paths:["background.color","buttonStyle.grid-button-primary-color","buttonStyle.grid-button-primary-color-hover","buttonStyle.grid-button-primary-color-active","buttonStyle.grid-button-primary-background-color","buttonStyle.grid-button-primary-background-color-hover","buttonStyle.grid-button-primary-border-color","buttonStyle.grid-button-primary-border-color-active","buttonStyle.grid-button-primary-border-color-hover","buttonStyle.grid-button-secondary-color","buttonStyle.grid-button-secondary-color-hover","buttonStyle.grid-button-secondary-color-active","buttonStyle.grid-button-secondary-background-color","buttonStyle.grid-button-secondary-background-color-hover","buttonStyle.grid-button-secondary-border-color","buttonStyle.grid-button-secondary-border-color-active","buttonStyle.grid-button-secondary-border-color-hover","textColorVars.h1-color","textColorVars.h2-color","textColorVars.h3-color","textColorVars.h4-color","textColorVars.h5-color","textColorVars.h6-color","textColorVars.body-color","textColorVars.body-large-color","ribbonStyle.ribbon-color","ribbonStyle.ribbon-background-color"]},BlockBlogHeader:{paths:["background.color"]},BlockBlogList:{paths:["background.color"]},BlockImageSlideshow:{paths:["settings.styles.navigationDotsColor","settings.styles.navigationArrowsColor"]}},rH={GridButton:{paths:["fontColor","fontColorHover","backgroundColor","backgroundColorHover","borderColor","borderColorHover"]},GridEcommerceButton:{paths:["fontColor","fontColorHover","backgroundColor","backgroundColorHover","borderColor","borderColorHover"]},GridSocialIcons:{paths:["settings.styles.icon-color","settings.styles.icon-color-hover"]},GridShape:{paths:["color"]},GridTextBox:{paths:["backgroundColor"]},GridForm:{paths:["inputFillColor","inputFillColorHover","inputTextColor","inputTextColorHover","labelTextColor","formBorderColor","inputBorderColor","inputBorderColorHover","formBackgroundColor","submitButtonFontColor","submitButtonFontColorHover","submitButtonBackgroundColor","submitButtonBackgroundColorHover","submitButtonBorderColor","submitButtonBorderColorHover"]}},ea=[{alt:"black blue and yellow textile",path:"photo-1584443348278-4789e86c7373?auto=format&fit=crop&w=3600&h=2160",origin:"unsplash"},{alt:"a man riding a skateboard down the side of a ramp",path:"photo-1563164232-b6ee5dd3e821?auto=format&fit=crop&w=3600&h=2160",origin:"unsplash"},{alt:"white concrete building during daytime",path:"photo-1586522471252-68f4b108ff2a?auto=format&fit=crop&w=3600&h=2160",origin:"unsplash"},{alt:"worm's-eye view photography of concrete building",path:"photo-1483366774565-c783b9f70e2c?auto=format&fit=crop&w=861&",origin:"unsplash"},{alt:"photo of white staircase",path:"photo-1516739089214-59baa011fdb9?auto=format&fit=crop&w=3600&h=2160",origin:"unsplash"},{alt:"white concrete building",path:"photo-1578803203370-8b000b589edd?auto=format&fit=crop&w=3600&h=2160",origin:"unsplash"}],dH=[{id:"OwLII_JWsPQ",width:3374,height:5472,blur_hash:"LEFrFp.90ztSXp.9gPbx7%OZM|Iq",alt_description:"man and woman standing in front of brown concrete building during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"sauntered_globe",name:"Mos Sukjaroenkraisri",profile_image:{small:"https://images.unsplash.com/profile-1583491412391-1410a68650c6image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"1JM7_xehCVA",width:3428,height:4285,blur_hash:"LJNK9iRj_3%Mt7t8RPM{_Nt79FRj",alt_description:"black nikon dslr camera on white printer paper",urls:{raw:null,regular:null,thumb:null},user:{username:"yanagirl2020",name:"Yehleen gaffney",profile_image:{small:"https://images.unsplash.com/profile-1591105669703-5e2235d167eaimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"6AEYm85N10s",width:5184,height:3456,blur_hash:"L22$aJwID|J6wIj[OAW.D|S2-F$l",alt_description:"blue and white smoke illustration",urls:{raw:null,regular:null,thumb:null},user:{username:"sam_bad",name:"Sam",profile_image:{small:"https://images.unsplash.com/profile-1610802956174-98198d3b2ed2image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"_c_mdKbNuhA",width:2e3,height:3e3,blur_hash:"L6S$ln-;?^%g^*RjoztRyEof8_V@",alt_description:"red rose with green leaves",urls:{raw:null,regular:null,thumb:null},user:{username:"hddddck",name:"Steven Haddock",profile_image:{small:"https://images.unsplash.com/profile-fb-1607518974-17fa45487dc3.jpg?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"-yXUmnSgJMY",width:2160,height:2700,blur_hash:"LYNwNFj@~qt7?HRjayj[-;RiD%kC",alt_description:"woman in black long sleeve shirt and blue denim jeans sitting on white concrete wall",urls:{raw:null,regular:null,thumb:null},user:{username:"shinfe",name:"Shinfe Studio",profile_image:{small:"https://images.unsplash.com/profile-1618646035200-9aa08806d93fimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"ANTeIeA5F7U",width:6720,height:4480,blur_hash:"LLO:|b9D-q^-N;InM_xc_4Io9XRi",alt_description:"green vegetable on white ceramic plate",urls:{raw:null,regular:null,thumb:null},user:{username:"bakdandraw",name:"Bakd&Raw by Karolin Baitinger",profile_image:{small:"https://images.unsplash.com/profile-1619809393043-551ade2f028dimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"A52GGBS9GIU",width:3648,height:5472,blur_hash:"LC7^[6~U-o%L?Z-:tRkDW.of%1s:",alt_description:"woman in white and brown dress standing on green grass during night time",urls:{raw:null,regular:null,thumb:null},user:{username:"butenkovph",name:"Vadim Butenkov",profile_image:{small:"https://images.unsplash.com/profile-1626519549074-fb33db0fa642?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"r_ssUY27s9k",width:3520,height:5291,blur_hash:"LCFh^+.9EJ9t0K9u%gIp0KjD#+i^",alt_description:"man in white crew neck t-shirt wearing blue cap and black sunglasses",urls:{raw:null,regular:null,thumb:null},user:{username:"jayson_hinrichsen",name:"Jayson Hinrichsen",profile_image:{small:"https://images.unsplash.com/profile-1609483876126-c002704cc7bdimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"WStLwhx2xrk",width:6e3,height:4e3,blur_hash:"L44^{y1yi^+]5j,Ds;J.wJW;S3so",alt_description:"red blue and black abstract painting",urls:{raw:null,regular:null,thumb:null},user:{username:"pawel_czerwinski",name:"Pawel Czerwinski",profile_image:{small:"https://images.unsplash.com/profile-1592328433409-d9ce8a5333eaimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"1ox1IHwuSto",width:4480,height:6720,blur_hash:"L~LN=9s;WBj[~qj[ayj[t7WBj[ay",alt_description:"green mountain under white sky during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"joshuafuller",name:"Joshua Fuller",profile_image:{small:"https://images.unsplash.com/profile-1554115735018-2a9dad8cd52d?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"vCP1ISpPDaQ",width:2900,height:3999,blur_hash:"LHC6S{~Cnhad^+s.ayWB9YE1t7of",alt_description:"ocean waves crashing on shore during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"p_kuzovkova",name:"Polina Kuzovkova",profile_image:{small:"https://images.unsplash.com/profile-fb-1599732338-2f306e8de95c.jpg?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"oggezWlumg0",width:5999,height:3962,blur_hash:"L=J8YCxaj[kC~qs:j[j[IoWBj[f6",alt_description:"people sitting on grass field during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"naranbayar_1",name:"naraa .in.ub",profile_image:{small:"https://images.unsplash.com/profile-1615177125969-c83b477bcfccimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"OOs6WXfNV7Q",width:4e3,height:6e3,blur_hash:"LTIE|U9F00xu?wD%ofa#-:Rjt8Rj",alt_description:"water falls in the forest",urls:{raw:null,regular:null,thumb:null},user:{username:"bapt_g",name:"Baptiste Gousset",profile_image:{small:"https://images.unsplash.com/profile-1591787368767-6cc41486ba1aimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"XLBDdrNQwqo",width:4e3,height:6e3,blur_hash:"LGLET$Mvtl_NxmxvS6Ip9#R+nMaJ",alt_description:"woman in white hijab smiling",urls:{raw:null,regular:null,thumb:null},user:{username:"rehamyoussef",name:"reham youssef",profile_image:{small:"https://images.unsplash.com/profile-1627663735526-b871e15f0080image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"xEs5-bbbT3Q",width:3631,height:4539,blur_hash:"LWG[f*M{9F%M~qRjITt7x]jZRPof",alt_description:"empty hallway between concrete buildings during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"jupp",name:"Jonathan Kemper",profile_image:{small:"https://images.unsplash.com/profile-1594303873883-26aac065c921image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"cRY84RQE_Jg",width:3456,height:5184,blur_hash:"LMB2]Sxcp3NasAWTW7f4NZR%jDxb",alt_description:"woman in black shirt wearing sunglasses",urls:{raw:null,regular:null,thumb:null},user:{username:"photones11",name:"Julian Florez",profile_image:{small:"https://images.unsplash.com/profile-1532657867445-42e3a5a649d2?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"4p_i8cK8F0k",width:3696,height:5544,blur_hash:"LFH2f$4n~qM{-;IU%Mxu~q_NIUxu",alt_description:"woman in white crew neck shirt wearing brown sun hat",urls:{raw:null,regular:null,thumb:null},user:{username:"juniorreisfoto",name:"Junior REIS",profile_image:{small:"https://images.unsplash.com/profile-1616725924591-59ed46e6d1c1image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"KgLlSno7RLI",width:5472,height:3648,blur_hash:"L8AdDb8w4q.88^yEs;nMH]tQoxNH",alt_description:"person holding black and gray digital camera",urls:{raw:null,regular:null,thumb:null},user:{username:"druks",name:"Félix Besombes",profile_image:{small:"https://images.unsplash.com/profile-1606241009900-68ae4d356f0cimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"mz6USxR49PA",width:5174,height:7757,blur_hash:"L039MjEyNF~UujspjcE22]xGn69b",alt_description:"brown wooden house on lake",urls:{raw:null,regular:null,thumb:null},user:{username:"patresinger",name:"Patrick Langwallner",profile_image:{small:"https://images.unsplash.com/profile-1560256656985-c0a8e0d586a9?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"c8hi_P21Rn4",width:5375,height:3583,blur_hash:"LkJI|l.TofkC.9axMxWBbHRPoftR",alt_description:"gray concrete building during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"parrish",name:"Parrish Freeman",profile_image:{small:"https://images.unsplash.com/profile-1620080049469-43b9e29768daimage?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"FNqJ5eBfS0o",width:3744,height:4680,blur_hash:"L25N_p5RM_Ef~VE1kB%2J,RP-p-V",alt_description:"woman with brown hair wearing white and black floral hijab",urls:{raw:null,regular:null,thumb:null},user:{username:"isaakarsworld",name:"IsaaK Alexandre KaRslian",profile_image:{small:"https://images.unsplash.com/profile-1627600930154-659900cd0ed6image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"jhIj1hiInto",width:3335,height:2500,blur_hash:"L4BW**xu?vkDWXIAV[j?4TozITt8",alt_description:"black berries on black surface",urls:{raw:null,regular:null,thumb:null},user:{username:"universaleye",name:"Universal Eye",profile_image:{small:"https://images.unsplash.com/profile-1615170883424-223c49bef768image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"PncLQT6msjo",width:3643,height:5829,blur_hash:"L78;Z5R,4mxa-;WCE0t6D$axWVj[",alt_description:"white and brown train door",urls:{raw:null,regular:null,thumb:null},user:{username:"dayee",name:"大爷 您",profile_image:{small:"https://images.unsplash.com/profile-1588138840136-215eab923c60image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"qCKHDq-88-g",width:3908,height:5862,blur_hash:"L=IORpxuRjj[~qt7WAj[%NWBWBof",alt_description:"man in gray jacket and black backpack standing on green grass field near mountain during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"gantas",name:"Gantas Vaičiulėnas",profile_image:{small:"https://images.unsplash.com/profile-1594981205756-88eda384bff2image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"H4Xlh-B_7Rg",width:4160,height:6240,blur_hash:"L@KxC.jEkCoz~qRjayof-;j[WVWB",alt_description:"brown wooden house near lake surrounded by green trees during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"sueleewright",name:"Suelee Wright",profile_image:{small:"https://images.unsplash.com/profile-1628619441825-fd7629dd0420image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"SjqDB6bAZJk",width:3648,height:5472,blur_hash:"L15rA5?vD%xu_NtRV@ofRjayj[j]",alt_description:"black and white concrete building",urls:{raw:null,regular:null,thumb:null},user:{username:"dylanhendricks",name:"Dylann Hendricks | 딜란",profile_image:{small:"https://images.unsplash.com/profile-1614483709506-7ca421e00f40image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"jsnqiE1WF1s",width:3150,height:4724,blur_hash:"LC6Ru?-:Dh9GL}RPt-tlKkOFrpwb",alt_description:"woman in blue and white shirt",urls:{raw:null,regular:null,thumb:null},user:{username:"benmasora",name:"Ben Masora",profile_image:{small:"https://images.unsplash.com/profile-fb-1590605336-8440ca965b17.jpg?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"2UZ4kQRImVg",width:5464,height:8192,blur_hash:"LoLO4poLaeWB?^WBofs:%gofRjRj",alt_description:"man in black suit standing beside woman in white wedding dress",urls:{raw:null,regular:null,thumb:null},user:{username:"nate_dumlao",name:"Nathan Dumlao",profile_image:{small:"https://images.unsplash.com/profile-1495427732560-fe5248ad6638?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"sZDkAPqTypU",width:2624,height:3936,blur_hash:"LA8NkZSixut8x{ogV?a#0Js,M_ae",alt_description:"brown concrete building under starry night",urls:{raw:null,regular:null,thumb:null},user:{username:"piensaenpixel",name:"Emilio Garcia",profile_image:{small:"https://images.unsplash.com/profile-1523306443217-4c56454b65ca?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}},{id:"BVWE9KD2sIw",width:5568,height:3712,blur_hash:"L}PF.RxEWEay.ASNkCj[Neaynia#",alt_description:"yellow sunflower field during daytime",urls:{raw:null,regular:null,thumb:null},user:{username:"kristapsungurs",name:"Kristaps Ungurs",profile_image:{small:"https://images.unsplash.com/profile-1572640061210-c7b0e4c77d42image?ixlib=rb-1.2.1&q=80&fm=jpg&crop=faces&cs=tinysrgb&fit=crop&h=32&w=32"}}}],__=[{paletteId:`${An.PALETTE}-1`,color1:"#EFF2F9",color2:"#617DA1",color3:"#21272E",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-2`,color1:"#F5EBE0",color2:"#7A6B5F",color3:"#382E27",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-3`,color1:"#F0EEF2",color2:"#1F2130",color3:"#8B728E",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-4`,color1:"#EEEDEB",color2:"#5E665C",color3:"#262625",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-5`,color1:"#F2F2F2",color2:"#4D4D4D",color3:"#1A1A1A",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-6`,color1:"#ECEFF3",color2:"#416BD7",color3:"#101840",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-7`,color1:"#FFEACC",color2:"#211E1B",color3:"#CC6333",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-8`,color1:"#FFE5D9",color2:"#242666",color3:"#686DF3",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-9`,color1:"#F4F4F4",color2:"#E5525F",color3:"#261F1F",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-10`,color1:"#FFFAB2",color2:"#725EED",color3:"#2D236D",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"},{paletteId:`${An.PALETTE}-11`,color1:"#F2F1E6",color2:"#1B1F1C",color3:"#31A050",light:"#FFFFFF",dark:"#1A1A1A",grey:"#B8BECC"}],Ln={en:{disclaimer:"This website uses cookies to provide necessary site functionality and to improve your experience. By using this website, you agree to our use of cookies.",accept:"Accept",decline:"Decline",readTime:"min read"},af:{disclaimer:"Hierdie webwerf maak gebruik van koekies om nodige webwerf funksionaliteit te verskaf en om jou ervaring te verbeter. Deur hierdie webwerf te gebruik, stem jy saam met ons gebruik van koekies.",accept:"Aanvaar",decline:"Weier",readTime:"min lees"},ar:{disclaimer:"يستخدم هذا الموقع ملفات تعريف الارتباط لتوفير وظائف الموقع اللازمة وتحسين تجربتك. عن طريق استخدام هذا الموقع ، فإنك توافق على استخدامنا لملفات تعريف الارتباط.",accept:"قبول",decline:"انخفاض",readTime:"دقيقة قراءة"},az:{disclaimer:"Bu veb sayt tələb olunan sayt funksionalitətini təmin etmək və təcrübənizi yaxşılaşdırmaq üçün çerezlərdən istifadə edir. Bu veb saytı istifadə edərək, bizim çerezlərdən istifadəmizə razılaşmış olursunuz.",accept:"Qəbul edin",decline:"Rədd olun",readTime:"dəqiqə oxu"},bg:{disclaimer:"Този уебсайт използва бисквитки, за да осигури необходимите функции на сайта и да подобри вашето изживяване. С използването на този уебсайт вие се съгласявате с нашето използване на бисквитки.",accept:"Приеми",decline:"Откажи",readTime:"мин четене"},bn:{disclaimer:"এই ওয়েবসাইটটি প্রয়োজনীয় সাইট কার্যক্রম সরবরাহ করতে এবং আপনার অভিজ্ঞতা উন্নত করতে কুকিজ ব্যবহার করে। এই ওয়েবসাইটটি ব্যবহার করে আপনি আমাদের কুকিজ ব্যবহারের সাথে সম্মত হন।",accept:"গ্রহণ করা",decline:"অস্বীকার",readTime:"মিনিট পড়ুন"},bs:{disclaimer:"Ova web stranica koristi kolačiće za pružanje potrebne funkcionalnosti web stranice i poboljšanje vašeg iskustva. Korištenjem ove web stranice pristajete na naše korištenje kolačića.",accept:"Prihvati",decline:"Odbiti",readTime:"min čitanje"},cs:{disclaimer:"Tato webová stránka používá soubory cookie k poskytování nezbytných funkcí webové stránky a zlepšení vašeho zážitku. Používáním této webové stránky souhlasíte s naším používáním souborů cookie.",accept:"Akceptovat",decline:"Odmítnout",readTime:"min čtení"},da:{disclaimer:"Denne webside bruger cookies til at levere nødvendig webstedsfunktionalitet og forbedre din oplevelse. Ved at bruge denne webside accepterer du vores brug af cookies.",accept:"Acceptere",decline:"Nedgang",readTime:"min læsning"},de:{disclaimer:"Diese Website verwendet Cookies, um notwendige Website-Funktionen bereitzustellen und Ihre Erfahrung zu verbessern. Durch die Nutzung dieser Website stimmen Sie unserer.",accept:"Annehmen",decline:"Ablehnen",readTime:"min lesen"},et:{disclaimer:"See veebisait kasutab küpsiseid vajaliku veebisaidi funktsionaalsuse tagamiseks ja teie kogemuse parandamiseks. Selle veebisaidi kasutamisega nõustute meie küpsiste kasutamisega.",accept:"Nõustu",decline:"Keeldumine",readTime:"min lugemine"},el:{disclaimer:"Αυτός ο ιστότοπος χρησιμοποιεί cookies για να παρέχει απαραίτητες λειτουργίες ιστότοπου και για να βελτιώσει την εμπειρία σας. Χρησιμοποιώντας αυτόν τον ιστότοπο, συμφωνείτε με τη χρήση cookies από εμάς.",accept:"Αποδέχομαι",decline:"Πτώση",readTime:"λεπτά ανάγνωσης"},es:{disclaimer:"Este sitio web utiliza cookies para proporcionar las funciones del sitio necesarias y mejorar su experiencia. Al utilizar este sitio web, acepta nuestro uso de cookies.",accept:"Aceptar",decline:"Rechazar",readTime:"min leer"},eu:{disclaimer:"Webgune honek cookie-ak erabiltzen ditu gunearen funtzionaltasuna eskaintzeko eta zure esperientzia hobetzeko. Webgune hau erabiltzean, gure cookieen erabilera onartzen duzu.",accept:"Onartu",decline:"Gainbehera",readTime:"min irakurri"},fr:{disclaimer:"Ce site utilise des cookies pour fournir les fonctionnalités de site nécessaires et améliorer votre expérience. En utilisant ce site, vous acceptez notre utilisation des cookies.",accept:"Accepter",decline:"Décliner",readTime:"min temps de lecture"},gu:{disclaimer:"આ વેબસાઇટ આવશ્યક વેબસાઇટ કાર્યક્ષમતા પૂરી કરવા અને તમારી અનુભવને સુધારવા માટે કુકીઝનો ઉપયોગ કરે છે. આ વેબસાઇટનો ઉપયોગ કરીને તમે અમારા કુકીઝનો ઉપયોગ સહમત થાઓ છો.",accept:"સ્વીકારો",decline:"અસ્વીકાર",readTime:"મિનિટ વાંચો"},zh:{disclaimer:"本网站使用cookie提供必要的网站功能并改善您的体验。使用本网站即表示您同意我们使用cookie。",accept:"接受",decline:"拒绝",readTime:"分钟阅读"},ko:{disclaimer:"이 웹 사이트는 필수 사이트 기능을 제공하고 경험을 향상시키기 위해 쿠키를 사용합니다. 이 웹 사이트를 사용하면 쿠키 사용에 동의하는 것으로 간주됩니다.",accept:"수용하다",decline:"감소",readTime:"분 읽기"},hi:{disclaimer:"यह वेबसाइट आपके अनुभव को सुधारने और आवश्यक वेबसाइट कार्यक्षमता प्रदान करने के लिए कुकीज़ का उपयोग करती है। इस वेबसाइट का उपयोग करके, आप हमारे कुकीज़ का उपयोग स्वीकार करते हैं।",accept:"स्वीकार करना",decline:"पतन",readTime:"मिनट पढ़ें"},kn:{disclaimer:"ಈ ವೆಬ್ಸೈಟ್ ಅವಶ್ಯಕ ವೆಬ್ಸೈಟ್ ಕೆಲಸಗಳನ್ನು ನೀಡಲು ಮತ್ತು ನಿಮ್ಮ ಅನುಭವವನ್ನು ಉತ್ತಮಗೊಳಿಸಲು ಕುಕೀಗಳನ್ನು ಬಳಸುತ್ತದೆ. ಈ ವೆಬ್ಸೈಟ್ ಅನ್ವಯಿಸಲು ನಿಮ್ಮ ಕುಕೀಗಳ ಬಳಸಲು ನಿಮ್ಮ ಸಹಾಯವನ್ನು ನೀಡುತ್ತದೆ.",accept:"ಒಪ್ಪಿಕೊಳ್ಳಿ",decline:"ನಿರಾಕರಿಸು",readTime:"ನಿಮಿಷ ಓದಿ"},hr:{disclaimer:"Ova web stranica koristi kolačiće za osiguranje nužnih web stranica funkcija i poboljšanje vašeg iskustva. Korištenjem ove web stranice prihvaćate našu upotrebu kolačića.",accept:"Prihvatiti",decline:"Odbiti",readTime:"min čitanje"},id:{disclaimer:"Situs web ini menggunakan cookie untuk menyediakan fungsi situs yang diperlukan dan meningkatkan pengalaman Anda. Dengan menggunakan situs web ini, Anda menyetujui penggunaan cookie kami.",accept:"Menerima",decline:"Menolak",readTime:"min baca"},is:{disclaimer:"Þessi vefur notar kökur til að veita nauðsynlegum vefsvæðisföllum og auka reynslu þína. Með því að nota þennan vef notar þú samþykkið okkar notkun á kökum.",accept:"Taka",decline:"Afneita",readTime:"min lesa"},it:{disclaimer:"Questo sito utilizza i cookie per fornire le funzionalità del sito necessarie e migliorare la tua esperienza. Utilizzando questo sito, accetti il nostro utilizzo dei cookie.",accept:"Accetto",decline:"Declinare",readTime:"min leggere"},he:{disclaimer:"אתר זה משתמש בעוגיות כדי לספק את התכונות הנדרשות של האתר ולשפר את החוויה שלך. באמצעות שימוש באתר זה, אתה מסכים לשימוש שלנו בעוגיות.",accept:"לְקַבֵּל",decline:"יְרִידָה",readTime:"דקה לקרוא"},ku:{disclaimer:"ئەم وێبگەیە کوکییەکان بۆ بەرهەمکردنی تایبەتمەندییەکانی وێبگەیەکان و بهبودی تێبینییەکانتان بەکاردێت. بەکارهێنانی ئەم وێبگەیە، ئەم کوکییەکان بەکاردێتەوەیانیانیان.",accept:"پەسەندکردن",decline:"ڕەتکردنەوە",readTime:"خولەک خوێندن"},lv:{disclaimer:"Šī vietne izmanto sīkdatnes, lai nodrošinātu nepieciešamo vietnes funkcionalitāti un uzlabotu jūsu pieredzi. Šī vietne izmantojot, jūs piekrītat mūsu sīkdatņu izmantošanai.",accept:"Pieņemt",decline:"Noraidīt",readTime:"min lasīt"},lb:{disclaimer:"Dës Säit benotzt Cookies fir déi néideg Funktiounen ze gewährleisten an Är Erfoerderung ze verbesseren. Wann Dir dës Säit benotzt, akzeptéiert Dir datt eng Benotzung vun ärer Cookies.",accept:"Akzeptéieren",decline:"Decline",readTime:"min liesen"},lt:{disclaimer:"Šioje svetainėje naudojami slapukai, kad būtų pateikiamos reikalingos svetainės funkcijos ir pagerintų jūsų patirtį. Naudojant šią svetainę, jūs sutinkate su mūsų slapukų naudojimu.",accept:"Sutinku",decline:"Nesutinku",readTime:"min skaitymo"},lk:{disclaimer:"මෙම වෙබ් අඩවිය අවශ්ය වෙබ් අඩවි ක්රියාකරන සහ ඔබේ අතුරුමුහුණත් වැඩිදුර සඳහා කුකීයි භාවිතා කරයි. මෙම වෙබ් අඩවිය භාවිතා කිරීමෙන්, ඔබ අපේ කුකීයි භාවිතා කිරීමට සත්ය වේ.",accept:"හරි",decline:"අවලංගු කරන්න",readTime:"මිනිත්තු කියවන්න"},hu:{disclaimer:"Ez a webhely cookie-kat használ a szükséges webhely funkciók biztosításához és az Ön élményének javításához. A webhely használatával Ön elfogadja a cookie-k használatát.",accept:"Elfogad",decline:"Elutasít",readTime:"perc olvasás"},mk:{disclaimer:"Оваа веб-страница користи колачиња за да ги обезбеди потребните функции на веб-страницата и да ја подобри вашата експериенца. Користејќи ја оваа веб-страница, вие се согласувате со нашата употреба на колачиња.",accept:"Прифати",decline:"Одбивање",readTime:"мин читање"},mn:{disclaimer:"Энэ вэб сайт нь шаардлагатай сайтын ажиллагааг хангах, таны туршлагыг сайжруулах зорилгоор күүки ашигладаг. Энэ вэбсайтыг ашигласнаар та күүки ашиглахыг зөвшөөрч байна.",accept:"Зөвшөөрөх",decline:"Татгалзах",readTime:"мин унших"},mt:{disclaimer:"Din il-websajt jagħmlu użu ta' cookies biex tikkonferma l-funzjonijiet bżonnija tal-websajt u biex tikkwalifika l-espjencija tiegħek. B'użu tal-websajt din, inti tikkonsenti l-użu ta' cookies tiegħek.",accept:"Aċċetta",decline:"Tnaqqis",readTime:"min taqra"},mr:{disclaimer:"हा संकेतस्थळ आवश्यक संकेतस्थळ कार्यक्षमता पुरवण्यासाठी आणि आपल्या अनुभवाचे सुधारणा करण्यासाठी कुकीज वापरतो. हा संकेतस्थळ वापरताना, आपण आमच्या कुकीज वापरण्याची सहमती देता.",accept:"स्वीकारा",decline:"अस्वीकार",readTime:"मिनिटे वाचा"},ro:{disclaimer:"Acest site folosește cookie-uri pentru a furniza funcționalitățile site-ului necesare și pentru a îmbunătăți experiența dvs. Prin utilizarea acestui site, sunteți de acord cu utilizarea noastră a cookie-urilor.",accept:"Accept",decline:"Declin",readTime:"min citit"},ja:{disclaimer:"このウェブサイトでは、必要なサイト機能を提供し、お客様の体験を向上させるためにクッキーを使用しています。 このウェブサイトを使用することで、クッキーの使用に同意するものとみなされます。",accept:"承認",decline:"却下",readTime:"分読む"},nl:{disclaimer:"Deze website maakt gebruik van cookies om noodzakelijke sitefunctionaliteit te bieden en uw ervaring te verbeteren. Door deze website te gebruiken, gaat u akkoord met ons gebruik van cookies.",accept:"Aanvaarden",decline:"Afwijzen",readTime:"min lezen"},no:{disclaimer:"Denne nettsiden bruker informasjonskapsler for å sikre nødvendige nettstedfunksjoner og forbedre din opplevelse. Ved å bruke denne nettsiden, samtykker du til vår bruk av informasjonskapsler.",accept:"Aksepterer",decline:"Avslå",readTime:"min lese"},pl:{disclaimer:"Ta strona internetowa wykorzystuje pliki cookie, aby zapewnić niezbędne funkcje witryny i poprawić Twoje doświadczenie. Korzystając z tej witryny internetowej, zgadzasz się na nasze wykorzystywanie plików cookie.",accept:"Akceptuj",decline:"Odrzuć",readTime:"min czytać"},pt:{disclaimer:"Este site usa cookies para fornecer funcionalidades do site necessárias e melhorar sua experiência. Ao usar este site, você concorda com o uso de cookies por nossa parte.",accept:"Aceitar",decline:"Rejeitar",readTime:"min ler"},pa:{disclaimer:"ਇਹ ਵੈੱਬਸਾਈਟ ਜ਼ਰੂਰੀ ਸਾਈਟ ਕਾਰਜਕੁਸ਼ਲਤਾ ਪ੍ਰਦਾਨ ਕਰਨ ਅਤੇ ਤੁਹਾਡੇ ਅਨੁਭਵ ਨੂੰ ਬਿਹਤਰ ਬਣਾਉਣ ਲਈ ਕੂਕੀਜ਼ ਦੀ ਵਰਤੋਂ ਕਰਦੀ ਹੈ। ਇਸ ਵੈੱਬਸਾਈਟ ਦੀ ਵਰਤੋਂ ਕਰਕੇ, ਤੁਸੀਂ ਸਾਡੀ ਕੂਕੀਜ਼ ਦੀ ਵਰਤੋਂ ਲਈ ਸਹਿਮਤ ਹੁੰਦੇ ਹੋ।",accept:"ਸਵੀਕਾਰ ਕਰੋ",decline:"ਅਸਵੀਕਾਰ ਕਰੋ",readTime:"ਮਿੰਟ ਪੜ੍ਹੇ"},ru:{disclaimer:"Этот сайт использует файлы cookie, чтобы обеспечить необходимые функции сайта и улучшить ваш опыт. Используя этот сайт, вы соглашаетесь с нашим использованием файлов cookie.",accept:"Принимать",decline:"Отклонить",readTime:"мин чтение"},sk:{disclaimer:"Táto webová stránka používa súbory cookie na poskytovanie potrebných funkcií webovej stránky a na zlepšenie vašej skúsenosti. Používaním tejto webovej stránky súhlasíte s naším používaním súborov cookie.",accept:"súhlasiť",decline:"Odmietnuť",readTime:"min čítanie"},sl:{disclaimer:"Ta spletna stran uporablja piškotke, da zagotovi potrebne funkcije spletnega mesta in izboljša vaše izkušnje. S tem spletnim mestom se strinjate z našim uporabljanjem piškotkov.",accept:"Sprejmi",decline:"Zavrni",readTime:"min branje"},sv:{disclaimer:"Denna webbplats använder cookies för att tillhandahålla nödvändiga webbplatsfunktioner och förbättra din upplevelse. Genom att använda denna webbplats samtycker du till vår användning av cookies.",accept:"Acceptera",decline:"Nedgång",readTime:"min läsa"},sr:{disclaimer:"Ovaj sajt koristi kolačiće da bi obezbedio neophodne funkcije sajta i poboljšao vašu iskustvo. Korišćenjem ovog sajta, saglasni ste sa našom upotrebom kolačića.",accept:"Прихвати",decline:"Одбити",readTime:"мин читање"},sq:{disclaimer:"Ky website përdor cookies për të siguruar funksionalitetin e nevojshëm të faqes dhe për të përmirësuar eksperiencën tuaj. Duke përdorur këtë website, ju pranoni përdorimin tonë të cookies.",accept:"Pranoj",decline:"Refuzoj",readTime:"min lexim"},sd:{disclaimer:"هي ويب سائيٽ ڪوڪيز استعمال ڪري ٿي ضروري سائيٽ جي ڪارڪردگي مهيا ڪرڻ ۽ توهان جي تجربي کي بهتر ڪرڻ لاءِ. هن ويب سائيٽ کي استعمال ڪندي، توهان اسان جي ڪوڪيز جي استعمال سان متفق آهيو.",accept:"قبول ڪريو",decline:"رد ڪرڻ",readTime:"منٽ وڻڻ"},fi:{disclaimer:"Tämä verkkosivusto käyttää evästeitä tarjotakseen sivuston tarvittavat toiminnot ja parantaa kokemustasi. Käyttämällä tätä verkkosivustoa, hyväksyt evästeiden käytön.",accept:"Hyväksy",decline:"Hylkää",readTime:"min lukea"},ta:{disclaimer:"இந்த வலைத்தளம் தேவையான தள செயல்பாடுகளை வழங்க குக்கீகளைப் பயன்படுத்துகிறது மற்றும் உங்கள் அனுபவத்தை மேம்படுத்துகிறது. இந்த வலைத்தளத்தைப் பயன்படுத்துவதன் மூலம், நீங்கள் குக்கீகளைப் பயன்படுத்துகிறீர்கள் என்று நாங்கள் ஒப்புக்கொள்கிறீர்கள்.",accept:"ஏற்கனவே",decline:"மறுக்குக",readTime:"நிமிடங்கள் வாசிக்கவும்"},te:{disclaimer:"ఈ వెబ్సైట్ వెబ్సైట్ అవసరమైన వెబ్సైట్ ఫీచర్లను అందిస్తుంది మరియు మీ అనుభవాన్ని మెరుగుపరచుకోవడానికి కుకీలను ఉపయోగిస్తుంది. ఈ వెబ్సైట్ను ఉపయోగించినప్పుడు, మీరు మా కుకీల ఉపయోగాన్ని ఆమోదించుకుంటారు.",accept:"అంగీకరించండి",decline:"తిరస్కరించండి",readTime:"నిమిషాలు చదవండి"},th:{disclaimer:"เว็บไซต์นี้ใช้คุกกี้เพื่อให้คุณได้รับคุณสมบัติของเว็บไซต์ที่จำเป็นและเพื่อปรับปรุงประสบการณ์ของคุณ โดยการใช้เว็บไซต์นี้ คุณยอมรับการใช้คุกกี้ของเรา",accept:"ยอมรับ",decline:"ปฏิเสธ",readTime:"นาทีอ่าน"},vi:{disclaimer:"Trang web này sử dụng cookie để cung cấp các tính năng cần thiết của trang web và cải thiện trải nghiệm của bạn. Bằng cách sử dụng trang web này, bạn đồng ý với việc sử dụng cookie của chúng tôi.",accept:"Chấp nhận",decline:"Từ chối",readTime:"phút đọc"},tr:{disclaimer:"Bu web sitesi, gerekli web sitesi özelliklerini sağlamak ve deneyiminizi geliştirmek için çerez kullanır. Bu web sitesini kullanarak, çerezlerimizin kullanımına katılıyorsunuz.",accept:"Kabul",decline:"Reddetmek",readTime:"min oku"},uk:{disclaimer:"Цей сайт використовує файли cookie, щоб забезпечити необхідні функції сайту та покращити ваш досвід. Використовуючи цей сайт, ви погоджуєтеся з нашим використанням файлів cookie.",accept:"прийняти",decline:"відхилити",readTime:"хв читати"},ur:{disclaimer:"یہ ویب سائٹ کوکیز کو ضروری سائٹ کی فعالیت فراہم کرنے اور آپ کے تجربے کو بہتر بنانے کے لیے استعمال کرتی ہے۔ اس ویب سائٹ کا استعمال کرتے ہوئے، آپ کوکیز کے ہمارے استعمال سے اتفاق کرتے ہیں۔",accept:"قبول کریں۔",decline:"رد کرنا",readTime:"منٹ پڑھیں"},fas:{disclaimer:"این وب سایت از کوکی ها برای ارائه ویژگی های لازم وب سایت و بهبود تجربه شما استفاده می کند. با استفاده از این وب سایت، شما با استفاده از کوکی های ما موافقت می کنید.",accept:"قبول",decline:"رد کردن",readTime:"دقیقه خواندن"}},ki={subsets:["latin"],variants:["regular","700"]},cH=[{category:"sans-serif",family:"Calibri",...ki},{category:"monospace",family:"Courier",...ki},{category:"sans-serif",family:"Comic Sans MS",...ki},{category:"monospace",family:"Courier New",...ki},{category:"serif",family:"Garamond",...ki},{category:"serif",family:"Georgia",...ki},{category:"sans-serif",family:"Helvetica",...ki},{category:"serif",family:"Palatino",...ki},{category:"sans-serif",family:"Tahoma",...ki},{category:"serif",family:"Times New Roman",...ki},{category:"sans-serif",family:"Trebuchet MS",...ki},{category:"sans-serif",family:"Verdana",...ki}],J6=' ',uH=t=>Rn(t).toRgbString(),pH=()=>(t,e)=>{e.data.styles=[],_s(t,"element",o=>{var n,s;if((n=o.properties)!=null&&n.style)try{e.data.styles=[...e.data.styles,T5((s=o.properties)==null?void 0:s.style)]}catch(a){console.error(a)}})},Vy=t=>{const{data:e}=vs().data("settings",ws).use(pH).processSync(t);return e.styles.map(o=>o==null?void 0:o.color).filter(o=>o!==void 0)},gH=(t,e,o)=>{var s;const n=(s=aH[o.type])==null?void 0:s.paths;return n?n.map(a=>{var i;const l=il(o,a);return!l||((i=o.background)==null?void 0:i.current)!=="gradient"?null:{path:`${t}.blocks.${e}.${a}`,value:{...l,isAnimated:!1}}}).filter(a=>a!==null):[]},mH=(t,e,o)=>{var s;const n=(s=lH[o.type])==null?void 0:s.paths;return n?n.map(a=>{var i;const l=il(o,a);return!l||((i=o.background)==null?void 0:i.current)!=="color"?null:{path:`${t}.blocks.${e}.${a}`,value:l}}).filter(a=>a!==null):[]},hH=(t,e,o)=>{var s;const n=(s=rH[o.type])==null?void 0:s.paths;return n?n.map(a=>{const l=il(o,a);return l?{path:`${t}.elements.${e}.${a}`,value:l}:null}).filter(a=>a!==null):[]},bH=(t,e,o)=>{var a;const n=(a=sH[o.type])==null?void 0:a.path;return n?Vy(il(o,n)).map(l=>({htmlPath:`${t}.elements.${e}.${n}`,value:l})):[]},tI=t=>Object.entries(t).flatMap(([e,{elements:o,blocks:n}])=>{const s=Object.entries(n).flatMap(([l,i])=>mH(e,l,i)),a=Object.entries(o).flatMap(([l,i])=>[...hH(e,l,i),...bH(e,l,i)]);return[...s,...a]}),fH=t=>Object.entries(t).flatMap(([e,{blocks:o}])=>Object.entries(o).flatMap(([s,a])=>gH(e,s,a))),yH=({pattern:t,replacement:e})=>o=>{_s(o,"element",n=>{var s;(s=n.properties)!=null&&s.style&&(n.properties.style=n.properties.style.replaceAll(t,e))})},eI=(t,e,o)=>tI(t).filter(n=>n.path?il(t,n.path)===e:n.htmlPath?Vy(il(t,n.htmlPath)).includes(e):!1).reduce((n,s)=>{if(s.path)return v_(n,s.path,o);if(s.htmlPath){const a=vs().data("settings",ws).use(yH,{pattern:e,replacement:o}).processSync(il(n,s.htmlPath)).toString();return v_(n,s.htmlPath,a)}return n},t),nm=()=>{const{getters:t}=nt(),e=c(()=>{if(Object.keys(t.siteLanguages).length===1)return t.siteLanguages;const{system:p,...g}=t.siteLanguages;return g}),o=c(()=>tI(e.value)),n=c(()=>fH(e.value)),s=c(()=>Yv(o.value,({value:p})=>p)),a=c(()=>Yv(n.value,({value:p})=>JSON.stringify(p))),l=c(()=>Object.fromEntries(Object.entries(s.value).map(([p,g])=>[p,g.length]))),i=c(()=>Object.fromEntries(Object.entries(a.value).map(([p,g])=>[p,g.length]))),r=c(()=>Object.fromEntries(Object.entries(l.value).filter(([p])=>p!=="transparent").sort((p,g)=>g[1]-p[1]))),u=c(()=>Object.fromEntries(Object.entries(i.value).sort((p,g)=>p-g)));return{getColorValue:uH,mostUsedColors:r,mostUsedGradients:u,updateColor:eI}},Tl=(t,e)=>{let o;return function(){const s=()=>Reflect.apply(t,this,arguments);clearTimeout(o),o=setTimeout(s,e)}},vH={class:"picker-selection"},_H={key:0},wH={class:"text-bold-2"},kH={class:"picker-gradient"},IH=["onClick"],SH=["color"],EH=["value"],xH={key:2,class:"gradient-slider"},TH={class:"text-bold-2"},CH=q({__name:"ColorPickerSelection",props:{color:{default:Pi},gradient:{default:()=>({isAnimated:!1,angle:0,colors:[{value:Pi},{value:Pi}]})},isGradient:{type:Boolean},isOpacityDisabled:{type:Boolean,default:!1}},emits:["update-color","update-gradient","toggle-eye-dropper"],setup(t,{emit:e}){const o=t,n=e,{getColorValue:s}=nm(),{isSupported:a,open:l}=zx(),i=C([{isActive:!0,value:o.gradient.colors[0].value||Pi},{isActive:!1,value:o.gradient.colors[1].value||Pi}]),r=c(()=>i.value.findIndex(T=>T.isActive)),u=c(()=>{const T=o.isGradient?i.value[r.value].value:o.color;return Rn(T).toRgbString()}),p=C(o.gradient.angle);Rt(()=>p.value,T=>{n("update-gradient",{...o.gradient,angle:T})}),Rt(()=>o.gradient,T=>{i.value=T.colors.map(({value:P},z)=>({isActive:i.value[z].isActive,value:P}))},{deep:!0});const g=T=>{i.value=i.value.map((P,z)=>({...P,isActive:z===T}))},b=c(()=>Rn(s(u.value)).toHexString()),y=T=>{if(o.isGradient){i.value[r.value].value=T;const P=i.value.map(z=>({value:s(z.value)}));n("update-gradient",{...o.gradient,colors:P});return}n("update-color",s(T))},k=T=>{Rn(T).isValid()&&y(T)},I=async()=>{n("toggle-eye-dropper",!0);try{const T=await l();if(!T)return;y(T.sRGBHex)}catch{n("toggle-eye-dropper",!1)}n("toggle-eye-dropper",!1)},E=Tl(T=>{k(T.target.value)},1e3);return(T,P)=>{const z=ct("qa");return d(),v("div",vH,[T.isGradient?(d(),v("div",_H,[m("p",wH,w(T.$t("builder.gradientColors")),1),m("div",kH,[(d(!0),v(dt,null,zt(i.value,(L,D)=>(d(),v("button",{key:D,class:rt(["picker-gradient__button",{"picker-gradient__button--active":L.isActive}]),onClick:$=>g(D)},[m("span",{class:"picker-gradient__color",style:ne({backgroundColor:L.value})},null,4),h(lt,{name:"edit",dimensions:"20px"})],10,IH))),128))])])):B("",!0),m("rgba-string-color-picker",{color:u.value,onColorChanged:P[0]||(P[0]=Yt(L=>y(L.detail.value),["stop"]))},null,40,SH),O(m("input",{ref:"textInput",value:b.value,class:"picker-selection__text-input",type:"text",onKeydown:P[1]||(P[1]=Bi(L=>k(L.target.value),["enter"])),onBlur:P[2]||(P[2]=L=>k(L.target.value)),onInput:P[3]||(P[3]=(...L)=>f(E)&&f(E)(...L)),onFocus:P[4]||(P[4]=L=>T.$refs.textInput.select())},null,40,EH),[[z,"color-picker_text-input"]]),f(a)?(d(),S(ut,{key:1,"button-type":"outlined",class:"picker-selection__pick-color-button",onClick:I},{default:_(()=>[h(lt,{name:"colorize"}),j(" "+w(T.$t("common.pickColor")),1)]),_:1})):B("",!0),T.isGradient?O((d(),v("div",xH,[m("p",TH,w(T.$t("builder.gradientAngle")),1),O(h(Jo,{modelValue:p.value,"onUpdate:modelValue":P[5]||(P[5]=L=>p.value=L),"has-number-input":"",min:0,max:360,step:1},null,8,["modelValue"]),[[z,"color-picker_gradient-slider"]])])),[[z,"color-picker_gradient-slider"]]):B("",!0)])}}}),oI=H(CH,[["__scopeId","data-v-a58e2d4e"]]),PH={class:"color-picker-solid"},BH={key:0,class:"color-picker-solid__website-colors"},AH={class:"text-bold-2"},DH={class:"color-picker-solid__colors"},zH=["onClick"],$H=q({__name:"ColorPickerSolid",props:{color:{},hideWebsiteColors:{type:Boolean},isOpacityDisabled:{type:Boolean,default:!1}},emits:["update-color","toggle-eye-dropper"],setup(t,{emit:e}){const o=e,n=t,{mostUsedColors:s,getColorValue:a}=nm(),l=[...new Set(Object.keys(s.value).slice(0,16).map(i=>a(i)))];return Nt(()=>{o("update-color",n.color)}),(i,r)=>{const u=ct("qa");return d(),v("div",PH,[l!=null&&l.length&&!i.hideWebsiteColors?(d(),v("div",BH,[m("p",AH,w(i.$t("common.colorStyles")),1),m("div",DH,[(d(),v(dt,null,zt(l,p=>O(m("button",{key:p,class:rt(["color-picker-solid__color",{active:p===i.color}]),style:ne({backgroundColor:p}),onClick:g=>o("update-color",p)},null,14,zH),[[u,"builder-colorpicker-websitecolor-btn"]])),64))])])):B("",!0),h(oI,{color:i.color,"is-opacity-disabled":i.isOpacityDisabled,onUpdateColor:r[0]||(r[0]=p=>o("update-color",p)),onToggleEyeDropper:r[1]||(r[1]=p=>o("toggle-eye-dropper",p))},null,8,["color","is-opacity-disabled"])])}}}),LH=H($H,[["__scopeId","data-v-021facce"]]),OH={class:"color-picker-gradient"},RH={key:0,class:"color-picker-gradient__website-colors"},MH={class:"text-bold-2"},HH={class:"color-picker-gradient__gradients"},NH=["onClick"],GH=q({__name:"ColorPickerGradient",props:{gradient:{},isOpacityDisabled:{type:Boolean,default:!1}},emits:["update-gradient","toggle-eye-dropper"],setup(t,{emit:e}){const o=t,n=e,{mostUsedGradients:s}=nm(),a=[...new Set(Object.keys(s.value).map(i=>JSON.parse(i)).slice(0,16))],l=i=>C5.isEqual({...i,isAnimated:!1},{...o.gradient,isAnimated:!1});return Nt(()=>{n("update-gradient",o.gradient)}),(i,r)=>(d(),v("div",OH,[a.length?(d(),v("div",RH,[m("p",MH,w(i.$t("builder.websiteGradients")),1),m("div",HH,[(d(),v(dt,null,zt(a,u=>m("button",{key:JSON.stringify(u),class:rt(["color-picker-gradient__gradient",{active:l(u)}]),style:ne({background:f(Z0)(u)}),onClick:p=>n("update-gradient",{...u,isAnimated:i.gradient.isAnimated})},null,14,NH)),64))])])):B("",!0),h(oI,{"is-gradient":"",gradient:i.gradient,"is-opacity-disabled":i.isOpacityDisabled,onUpdateGradient:r[0]||(r[0]=u=>n("update-gradient",u)),onToggleEyeDropper:r[1]||(r[1]=u=>n("toggle-eye-dropper",u))},null,8,["gradient","is-opacity-disabled"])]))}}),FH=H(GH,[["__scopeId","data-v-fc86d367"]]),VH={class:"color-picker"},UH={key:0,class:"color-picker-header"},jH=["onClick"],WH=q({__name:"ColorPicker",props:{color:{default:Pi},gradient:{default:()=>({isAnimated:!1,angle:0,colors:[{value:Pi},{value:Pi}]})},current:{default:"color"},hasGradient:{type:Boolean},targetRef:{default:null},isButtonHidden:{type:Boolean},isOpen:{type:Boolean},placement:{default:"bottom-start"},offset:{default:4},portalSelector:{default:Ng},autoUpdate:{type:Boolean},flip:{type:Boolean,default:!0},hideWebsiteColors:{type:Boolean},isOpacityDisabled:{type:Boolean,default:!1}},emits:["update-color","update-gradient","click-outside","toggle"],setup(t,{emit:e}){const o=t,n=e,{t:s}=_t(),a=C(o.current==="gradient"?"gradient":"solid"),l=g=>a.value===g,i=c(()=>[{type:"solid",label:s("builder.solid"),action:()=>{a.value="solid"},isActive:l("solid")},{type:"gradient",label:s("builder.gradient"),action:()=>{a.value="gradient"},isActive:l("gradient")}]),{dispatch:r}=nt(),u=C(null),p=C(!1);return so(()=>{r("gui/updateIsColorPickerOpen",!1),n("click-outside")}),(g,b)=>{const y=ct("qa");return d(),v("div",null,[O((d(),v("div",{ref_key:"colorPickerButtonRef",ref:u,onClick:b[0]||(b[0]=k=>g.$emit("toggle"))},[vt(g.$slots,"default",{},()=>[h(Wc,{color:g.color},null,8,["color"])],!0)])),[[Qe,!g.isButtonHidden],[y,"builder-colorpicker-toggle-btn"]]),g.isOpen?(d(),S(ve,{key:0,"target-ref":g.targetRef||u.value,placement:g.placement,"portal-selector":g.portalSelector,offset:g.offset,flip:g.flip,"auto-update":g.autoUpdate,onClickOutside:b[5]||(b[5]=k=>g.$emit("click-outside"))},{default:_(()=>[O(m("div",VH,[g.hasGradient?(d(),v("div",UH,[(d(!0),v(dt,null,zt(i.value,k=>(d(),v("button",{key:k.type,class:rt(["color-picker-header__button",{"color-picker-header__button--active":k.isActive}]),onClick:k.action},w(k.label),11,jH))),128))])):B("",!0),l("solid")?(d(),S(LH,{key:1,color:g.color,"hide-website-colors":g.hideWebsiteColors,"is-opacity-disabled":g.isOpacityDisabled,onUpdateColor:b[1]||(b[1]=k=>n("update-color",k)),onToggleEyeDropper:b[2]||(b[2]=k=>p.value=k)},null,8,["color","hide-website-colors","is-opacity-disabled"])):(d(),S(FH,{key:2,gradient:g.gradient,"is-opacity-disabled":g.isOpacityDisabled,onUpdateGradient:b[3]||(b[3]=k=>n("update-gradient",k)),onToggleEyeDropper:b[4]||(b[4]=k=>p.value=k)},null,8,["gradient","is-opacity-disabled"]))],512),[[Qe,!p.value]])]),_:1},8,["target-ref","placement","portal-selector","offset","flip","auto-update"])):B("",!0)])}}}),ti=H(WH,[["__scopeId","data-v-4546693a"]]),qH={class:"color-picker-toggle"},YH={class:"text-bold-2"},KH={class:"text-bold-2"},ZH=q({__name:"ZyroFieldColorPicker",props:{color:{default:Pi},gradient:{default:()=>({angle:0,isAnimated:!1,colors:[{value:Pi},{value:Pi}]})},current:{},hasGradient:{type:Boolean},isOpen:{type:Boolean},label:{},placement:{default:"right-start"},portalSelector:{default:So},isOpacityDisabled:{type:Boolean,default:!1}},emits:["toggle","click-outside","update-color","update-gradient"],setup(t,{emit:e}){const o=t,n=e,s=c(()=>o.current==="gradient");return(a,l)=>{const i=ct("qa");return d(),v("div",null,[h(ti,{"has-gradient":a.hasGradient,current:a.current,"is-open":a.isOpen,color:a.color,gradient:a.gradient,placement:a.placement,flip:!1,"portal-selector":a.portalSelector,"is-opacity-disabled":a.isOpacityDisabled,onUpdateColor:l[0]||(l[0]=r=>n("update-color",r)),onUpdateGradient:l[1]||(l[1]=r=>n("update-gradient",r)),onToggle:l[2]||(l[2]=r=>n("toggle")),onClickOutside:l[3]||(l[3]=r=>n("click-outside"))},{default:_(()=>[m("div",qH,[m("p",YH,w(a.label),1),h(Wc,{"is-gradient":s.value,color:a.color,gradient:a.gradient},null,8,["is-gradient","color","gradient"])])]),_:1},8,["has-gradient","current","is-open","color","gradient","placement","portal-selector","is-opacity-disabled"]),s.value?(d(),v("div",{key:0,class:"gradient-animation-toggle",onClick:l[4]||(l[4]=r=>n("update-gradient",{...a.gradient,isAnimated:!a.gradient.isAnimated}))},[m("p",KH,w(a.$t("builder.animateGradient")),1),O(h(Gn,{"model-value":a.gradient.isAnimated,class:"zyro-field-toggle__switch"},null,8,["model-value"]),[[i,"gradient-animation-toggle-button"]])])):B("",!0)])}}}),Fo=H(ZH,[["__scopeId","data-v-854d2acf"]]),QH=t=>{try{return decodeURIComponent(t)}catch{return t}},im=({assets:t}={})=>{const{getters:e,dispatch:o}=nt(),{t:n}=_t(),s=c(()=>e["assets/folders"]),a=c(()=>e["assets/assetPaths"]),l=c(()=>e["assets/currentDirectory"]),i=c(()=>wR({directory:l.value,folders:s.value})),r=c(()=>t==null?void 0:t.value.filter(L=>!L.hasFailed)),u=c(()=>r.value.map(L=>{var Y,F;const D=((Y=L.url)==null?void 0:Y.split("/"))||[],$=D[D.length-1],A=!!$&&a.value[$];if(A){const W=A.path.split("/"),V=W[W.length-1],K=V.split("."),N=K.length>1?K.slice(0,-1).join("."):V,X=QH(N),et=Hr(L.url)?$:X;return{...L,name:et,altTag:A.altTag,path:A.path}}const{initialDirectory:M,...U}=L;return{...U,path:`${M}${(F=L.file)==null?void 0:F.name}`,altTag:L.altTag,name:""}})),p=c(()=>u.value.filter(L=>{const D=L.path.lastIndexOf("/")+1;return L.path.slice(0,D)===l.value})),g=async({id:L})=>{const D=Object.fromEntries(Object.entries(a.value).filter(([$])=>$!==L));await o("assets/addAssetsData",{assetsData:D})},b=({path:L})=>{const D=s.value.filter(({path:A})=>!A.startsWith(L)),$=Object.fromEntries(Object.entries(a.value).filter(([,{path:A}])=>!A.startsWith(L)));o("assets/overrideFoldersData",{folders:D,assetPaths:$})},y=({newName:L,id:D=null}={})=>{const $=L.replace(/[^\d A-Za-z]/g,"\\$&"),A=new RegExp(`^(${$})$`),M=i.value.filter(K=>K.id!==D);if(!M.some(K=>K.id!==D&&K.name.match(A)))return L;const Y=new RegExp(`^(${$}( ([(]\\d+[)])+)?)$`),W=M.filter(K=>K.name.match(Y)&&K.id!==D&&K.name!==L).sort((K,Z)=>K.name.localeCompare(Z.name)).map(K=>{const N=K.name.slice(0,-1).split("("),X=N[N.length-1];return Number.parseInt(X,10)}).filter(K=>K),V=Math.max(...W,0)+1;return`${L}${V?` (${V})`:""}`},k=()=>{const L=n("builder.foldersNewFolder"),D=y({newName:L});o("assets/addNewFolder",{folderName:D,formattedFolderName:J2(D)})},I=({newName:L,id:D,assetData:$})=>{const{path:A}=$,M=A.split("."),U=M.length>1?M[M.length-1]:"",F=A.split("/").slice(0,-1),W=U?`${encodeURIComponent(L)}.${U}`:encodeURIComponent(L),V=[...F,W].join("/");o("assets/addAssetsData",{assetsData:{...a.value,[D]:{...a.value[D],path:V}}})},E=({newAltTag:L,id:D})=>{const $=t_({assetsList:t,id:D});a.value[$]&&o("assets/addAssetsData",{assetsData:{...a.value,[$]:{...a.value[$],altTag:L}}})},T=({newName:L,id:D})=>{const{path:$}=s.value.find(K=>K.id===D),A=y({newName:L,id:D}),M=Object.keys(a.value).filter(K=>a.value[K].path.startsWith($)),U=$.split("/"),Y=J2(A);U.splice(-2,1,Y);const F=s.value.map(K=>K.id===D?{...K,path:K.path.replaceAll($,U.join("/")),name:A}:K.path.startsWith($)?{...K,path:K.path.replace($,U.join("/")),parentPath:K.parentPath.replace($,U.join("/"))}:K),W=Object.entries(a.value).map(([K,Z])=>M.includes(K)?[K,{path:Z.path.replaceAll($,U.join("/"))}]:[K,Z]),V=Object.fromEntries(W);o("assets/overrideFoldersData",{folders:F,assetPaths:V})};return{currentDirectory:l,validAssetsWithPaths:u,currentDirectoryValidAssets:p,currentDirectoryFolders:i,folders:s,assetPaths:a,deleteAssetFromFoldersData:g,deleteFolderFromFoldersData:b,addNewFolder:k,setAssetName:({newName:L,id:D})=>{const $=t_({assetsList:t,id:D}),A=a.value[$];if(A){I({newName:L,id:$,assetData:A});return}T({newName:L,id:D})},setImageAltTag:E,moveFileTo:({path:L,newPath:D,id:$})=>{const A=L.split("/"),M=A[A.length-1],U=`${D}${M}`,Y=Object.entries(a.value).map(([W,V])=>$===W?[W,{path:V.path.replaceAll(L,U)}]:[W,V]),F=Object.fromEntries(Y);o("assets/addAssetsData",{assetsData:F})}}},w_=t=>t.startsWith("https://assets.zyrosite.com")?{origin:"assets",path:Ia(t)}:t.startsWith("https://images.unsplash.com")?{origin:"unsplash",path:Ia(t)}:{origin:"other",path:t},k_=250,XH=q({props:{progress:{type:Number,default:33}},emits:["animation-finished"],computed:{computedStyles(){return{"--transition-time":`${k_}ms`,"--progress":this.progress}}},watch:{progress(t){t===100&&setTimeout(()=>{this.$emit("animation-finished")},k_)}}}),JH=t=>(ke("data-v-3167e12f"),t=t(),Ie(),t),tN=JH(()=>m("path",{class:"upload-loader__circle","stroke-dasharray":"100, 100",d:`M18 2.0845
a 15.9155 15.9155 0 0 1 0 31.831
a 15.9155 15.9155 0 0 1 0 -31.831`},null,-1)),eN={ref:"progressCircle",class:"upload-loader__circle upload-loader__progress-circle","stroke-dasharray":"0, 100",d:`M18 2.0845
a 15.9155 15.9155 0 0 1 0 31.831
a 15.9155 15.9155 0 0 1 0 -31.831`};function oN(t,e,o,n,s,a){return d(),v("svg",{style:ne(t.computedStyles),viewBox:"0 0 36 36",class:"upload-loader"},[tN,m("path",eN,null,512)],4)}const nI=H(XH,[["render",oN],["__scopeId","data-v-3167e12f"]]),nN=q({components:{ZyroSvgDeprecated:qt,UploadLoader:nI},props:{src:{type:String,required:!0},isFreshUpload:{type:Boolean,default:!1},loadPercentage:{type:Number,default:null},id:{type:String,required:!0}},emits:["click-image","cancel-upload"],data(){return{isAnimationFinished:!1}},computed:{isLoading(){return this.isFreshUpload&&(this.loadPercentage!==100||!this.isAnimationFinished)}}}),iN={class:"user-image__image-container"},sN=["src"],aN={key:0,class:"user-image__loader"};function lN(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated"),i=G("UploadLoader"),r=ct("qa");return d(),v("div",iN,[O(m("img",{src:t.src,class:"user-image__image",onDragstart:e[0]||(e[0]=Yt(()=>{},["prevent"])),onClick:e[1]||(e[1]=Yt(u=>t.$emit("click-image",{imageKey:t.id,e:u}),["stop"]))},null,40,sN),[[r,"chooseimage-uploadedimage"]]),vt(t.$slots,"default",{},void 0,!0),t.isLoading?(d(),v("div",aN,[h(l,{class:"user-image__loader-cancel",name:"x",onClick:e[2]||(e[2]=u=>t.$emit("cancel-upload",t.id))}),h(i,{class:"user-image__loader-svg",progress:t.loadPercentage,onAnimationFinished:e[3]||(e[3]=u=>t.isAnimationFinished=!0)},null,8,["progress"])])):B("",!0)])}const rN=H(nN,[["render",lN],["__scopeId","data-v-528a88a1"]]),dN=q({components:{Icon:lt,HostingerButton:ut,UserImage:rN},props:{images:{type:Object,required:!0},selectedImageKeys:{type:Array,default:()=>[]}},emits:["move-image","remove-from-gallery","cancel-upload"],data(){return{movedImageIndex:-1,hoveredImageIndex:-1,indicatorPosition:null,startMouseCoordinates:{x:0,y:0},mousePositionDifference:{x:0,y:0}}},computed:{movedImageOffset(){return{"--x":`${this.mousePositionDifference.x}px`,"--y":`${this.mousePositionDifference.y}px`}},nonMovedImageStyle(){return{"--cursor":this.movedImageIndex===-1?"grab":"move"}}},methods:{getImageStyle(t,e){return this.isImageMovable(t)?e===this.movedImageIndex?this.movedImageOffset:this.nonMovedImageStyle:""},resetState(){this.movedImageIndex=-1,this.hoveredImageIndex=-1,this.indicatorPosition=null,this.startMouseCoordinates={x:0,y:0},this.mousePositionDifference={x:0,y:0}},onHoverMovingImageOverImage(t,e){const o=t.currentTarget.getBoundingClientRect().left+t.currentTarget.clientWidth/2>t.clientX;this.hoveredImageIndex=e,this.indicatorPosition=o?"left":"right"},isImageMovable(t){return t.url&&!t.urlBase64},startMovingImage(t,e){this.movedImageIndex=e,this.startMouseCoordinates={x:t.clientX,y:t.clientY},window.addEventListener("mousemove",this.moveImage),window.addEventListener("mouseup",this.stopMovingImage)},moveImage(t){this.mousePositionDifference={x:t.clientX-this.startMouseCoordinates.x,y:t.clientY-this.startMouseCoordinates.y}},stopMovingImage(){const t=this.movedImageIndex+1===this.hoveredImageIndex&&this.indicatorPosition==="left",e=this.movedImageIndex-1===this.hoveredImageIndex&&this.indicatorPosition==="right";if(this.hoveredImageIndex!==-1&&!e&&!t){let o=this.hoveredImageIndex+(this.indicatorPosition==="right"?1:0);o+=this.movedImageIndexO((d(),S(r,{id:g,key:`image-${g}`,style:ne(t.getImageStyle(p,b)),class:rt({"horizontal-masonry__image-container--is-moved":b===t.movedImageIndex,[`horizontal-masonry__image-container--indicator-${t.indicatorPosition}`]:b===t.hoveredImageIndex}),src:p.urlBase64||p.url,"is-fresh-upload":!!p.urlBase64,"load-percentage":p.transferProgress,onCancelUpload:e[1]||(e[1]=y=>t.$emit("cancel-upload",y)),onMousedown:y=>t.isImageMovable(p)?t.startMovingImage(y,b):null,onMousemove:y=>t.movedImageIndex!==-1?t.onHoverMovingImageOverImage(y,b):null},{default:_(()=>[m("div",cN,[m("div",uN,[m("span",pN,w(b+1),1),t.isImageMovable(p)?O((d(),S(i,{key:0,class:"horizontal-masonry__gallery-overlay-cancel","button-type":"plain",theme:"highlight",title:t.$t("common.delete"),onMousedown:e[0]||(e[0]=Yt(()=>{},["stop"])),onClick:y=>t.$emit("remove-from-gallery",b)},{icon:_(()=>[h(l,{name:"delete",dimensions:"20px"})]),_:2},1032,["title","onClick"])),[[u,"gallerymanager-btn-delete"]]):B("",!0)])])]),_:2},1032,["id","style","class","src","is-fresh-upload","load-percentage","onMousedown","onMousemove"])),[[u,"gallerymanager-image"]])),128))],2)}const iI=H(dN,[["render",gN],["__scopeId","data-v-e9b97bee"]]),mN=q({components:{HostingerButton:ut,ZyroSvgDeprecated:qt},props:{isDraggedOver:{type:Boolean,default:!1}},emits:["open-file-dialog"]}),sI=t=>(ke("data-v-a723339b"),t=t(),Ie(),t),hN={class:"drag-and-drop-overlay drag-and-drop-overlay--dragged-over"},bN={class:"text-bold-1"},fN={class:"drag-and-drop-overlay__maximum-asset-size text-body-2"},yN=sI(()=>m("br",null,null,-1)),vN={key:1},_N={class:"drag-and-drop-overlay"},wN={class:"text-bold-1"},kN={class:"drag-and-drop-overlay__or text-body-1"},IN={class:"drag-and-drop-overlay__button"},SN={class:"drag-and-drop-overlay__maximum-asset-size text-body-2"},EN=sI(()=>m("br",null,null,-1));function xN(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated"),i=G("HostingerButton"),r=ct("qa");return t.isDraggedOver?(d(),S(Ee,{key:0,to:"body"},[m("div",hN,[h(l,{class:"drag-and-drop-overlay__icon",name:"cloud"}),m("p",bN,[vt(t.$slots,"drop-files-text",{},()=>[j(w(t.$t("builder.assetManagerTabUserDragDropFiles")),1)],!0)]),m("p",fN,[j(w(t.$t("builder.assetManagerTabUserMaximumImageSize"))+" ",1),yN,j(" "+w(t.$t("builder.assetManagerTabUserMaximumDocumentSize")),1)])])])):(d(),v("div",vN,[m("div",_N,[h(l,{class:"drag-and-drop-overlay__icon",name:"cloud"}),m("p",wN,[vt(t.$slots,"drop-files-text",{},()=>[j(w(t.$t("builder.assetManagerTabUserDragDropFiles")),1)],!0)]),m("p",kN,w(t.$t("builder.assetManagerTabUserOr")),1),m("div",IN,[vt(t.$slots,"placeholder-button",{},()=>[O((d(),S(i,{"button-type":"outlined",size:"sm",onClick:e[0]||(e[0]=u=>t.$emit("open-file-dialog"))},{default:_(()=>[j(w(t.$t("builder.assetManagerTabUserChooseFiles")),1)]),_:1})),[[r,"chooseimage-btn-browsefiles"]])],!0)]),m("p",SN,[j(w(t.$t("builder.assetManagerTabUserMaximumImageSize"))+" ",1),EN,j(" "+w(t.$t("builder.assetManagerTabUserMaximumDocumentSize")),1)])])]))}const Uy=H(mN,[["render",xN],["__scopeId","data-v-a723339b"]]),TN={class:"upload-bar"},CN={key:0,class:"upload-bar__drag-drop-text text-body-2"},PN={__name:"ImagesControlBar",emits:["open-asset-manager"],setup(t,{emit:e}){const o=e,{isAiBuilderMode:n}=vo(),s=()=>{o("open-asset-manager")};return(a,l)=>{const i=ct("qa");return d(),v("div",TN,[f(n)?B("",!0):(d(),v("p",CN,[h(lt,{name:"upload"}),j(" "+w(a.$t("builder.assetManagerTabUserDragDropBar")),1)])),O((d(),S(ut,{onClick:s},{"icon-left":_(()=>[h(lt,{name:"add"})]),default:_(()=>[j(" "+w(a.$t("builder.assetManagerGalleryAddImages")),1)]),_:1})),[[i,"assetmanager-addimage"]])])}}},aI=H(PN,[["__scopeId","data-v-6dc3e508"]]),BN=q({components:{Icon:lt,HostingerButton:ut,ImagesControlBar:aI,HorizontalMasonry:iI,DragDropOverlay:Uy},props:{galleryId:{type:String,required:!0}},emits:["open-asset-manager"],setup(t,e){const{listenForDragAndDrop:o,assets:n,isDraggedOver:s}=Ss(t),a=C(null),{updateElementHeightOnDevices:l}=Gi();return Nt(()=>{o(a.value)}),Rt(s,()=>e.emit("open-asset-manager")),{galleryLayoutRef:a,assets:n,isDraggedOver:s,updateElementHeightOnDevices:l}},computed:{...Ae(["websiteId"]),...le(["siteElements"]),images(){return this.siteElements[this.galleryId].images},imagesObject(){return{...this.images.map(t=>({url:jo(t.origin,t.path,this.websiteId,{width:200})}))}},isEmpty(){return Object.keys(this.imagesObject).length===0}},methods:{...be(["mergeCurrentElementData"]),moveImage(t){const e=[...this.images];e.splice(t.newIndex,0,e.splice(t.oldIndex,1)[0]),this.mergeCurrentElementData({elementData:{images:e}})},removeImageFromGallery(t){const e=[...this.images];e.splice(t,1),this.mergeCurrentElementData({elementData:{images:e}}),this.updateElementHeightOnDevices({elementId:this.galleryId})}}}),AN={ref:"galleryLayoutRef",class:"gallery-manager"};function DN(t,e,o,n,s,a){const l=G("Icon"),i=G("HostingerButton"),r=G("DragDropOverlay"),u=G("ImagesControlBar"),p=G("HorizontalMasonry"),g=ct("qa");return d(),v("div",AN,[t.isEmpty?(d(),S(r,{key:0,class:"gallery-manager__empty"},{"drop-files-text":_(()=>[j(w(t.$t("builder.assetManagerGalleryAddImagesWhenEmpty")),1)]),"placeholder-button":_(()=>[O((d(),S(i,{onClick:e[0]||(e[0]=b=>t.$emit("open-asset-manager"))},{"icon-left":_(()=>[h(l,{name:"cloud_upload"})]),default:_(()=>[j(" "+w(t.$t("builder.assetManagerGalleryAddImages")),1)]),_:1})),[[g,"chooseimage-btn-browsefiles"]])]),_:1})):(d(),v(dt,{key:1},[h(u,{onOpenAssetManager:e[1]||(e[1]=b=>t.$emit("open-asset-manager"))}),h(p,{images:t.imagesObject,onRemoveFromGallery:t.removeImageFromGallery,onMoveImage:t.moveImage},null,8,["images","onRemoveFromGallery","onMoveImage"])],64))],512)}const zN=H(BN,[["render",DN],["__scopeId","data-v-387a4dc2"]]),$N=C({}),If="forward",I_="backward",lI=({isAutoplayEnabled:t,isLoopEnabled:e,autoplayInterval:o,isTransitioning:n,slides:s}={})=>{const a=C(0),l=C(""),i=C(null),r=c(()=>s.value.length),u=c(()=>a.value===s.value.length-1),p=c(()=>a.value===0),g=c(()=>(!u.value||e.value)&&r.value>1&&!n.value),b=c(()=>(!p.value||e.value)&&r.value>1&&!n.value),y=()=>{if(g.value){if(l.value=If,e.value&&u.value){a.value=0;return}a.value+=1}},k=()=>{if(b.value){if(l.value=I_,e.value&&p.value){a.value=s.value.length-1;return}a.value-=1}},I=z=>{l.value=z>a.value?If:I_,a.value=z},E=()=>{i.value=setInterval(()=>{!e.value&&u.value||y()},o.value*1e3)},T=()=>{i.value&&(clearInterval(i.value),i.value=null)},P=()=>{T(),t.value&&E()};return t&&(t.value&&E(),Rt(t,()=>{t.value?E():T()}),Rt($x(),z=>{z==="visible"?E():T()})),o&&Rt(o,()=>{P()}),{slideshowRefs:$N,slideToNext:y,slideToPrevious:k,slideTo:I,slideDirection:l,slideCount:r,currentSlideIndex:a,slides:s,isLoopEnabled:e,isAutoplayEnabled:t,autoplayInterval:o,resetAutoplayInterval:P,setAutoplayInterval:E,clearAutoplayInterval:T,canSlideToNext:g,canSlideToPrevious:b}},LN={__name:"SlideshowManager",props:{slideshowId:{type:String,required:!0}},emits:["open-asset-manager"],setup(t,{emit:e}){const o=t,n=e,{state:s,getters:a,dispatch:l}=nt(),{isAiBuilderMode:i}=vo(),{listenForDragAndDrop:r,isDraggedOver:u}=Ss(o),{slideshowRefs:p}=lI(),{slideTo:g}=p.value[o.slideshowId],b=C(null);Nt(()=>{r(b.value)}),Rt(u,()=>n("open-asset-manager"));const y=c(()=>a.currentBlock.slides),k=c(()=>({...y.value.map(P=>({url:jo(P.origin,P.path,s.websiteId,{width:200})}))})),I=c(()=>Object.keys(k.value).length===0),E=({newIndex:P,oldIndex:z})=>{const L=[...y.value];L.splice(P,0,L.splice(z,1)[0]),l("updateBlockData",{blockId:o.slideshowId,blockData:{slides:L},merge:!0})},T=P=>{l("updateBlockData",{blockId:o.slideshowId,blockData:{slides:y.value.filter((z,L)=>L!==P)},merge:!0}),g(0)};return(P,z)=>{const L=ct("qa");return d(),v("div",{ref_key:"slideshowManagerRef",ref:b,class:"slideshow-manager"},[I.value&&!f(i)?(d(),S(Uy,{key:0,class:"slideshow-manager__empty"},{"drop-files-text":_(()=>[j(w(P.$t("builder.assetManagerSlideshowAddImagesWhenEmpty")),1)]),"placeholder-button":_(()=>[O((d(),S(ut,{onClick:z[0]||(z[0]=D=>P.$emit("open-asset-manager"))},{"icon-left":_(()=>[h(lt,{name:"cloud_upload"})]),default:_(()=>[j(" "+w(P.$t("builder.assetManagerSlideshowAddImages")),1)]),_:1})),[[L,"chooseimage-btn-browsefiles"]])]),_:1})):(d(),v(dt,{key:1},[h(aI,{onOpenAssetManager:z[1]||(z[1]=D=>P.$emit("open-asset-manager"))}),h(iI,{images:k.value,onRemoveFromGallery:T,onMoveImage:E},null,8,["images"])],64))],512)}}},ON=H(LN,[["__scopeId","data-v-466893fe"]]),RN=q({components:{HostingerButton:ut,Icon:lt},props:{imageData:{type:Object,required:!0},isLastImage:{type:Boolean,default:!1},isFirstImage:{type:Boolean,default:!1},isGallery:{type:Boolean,default:!1}},emits:["image-loaded","select-image","show-previous-image","show-next-image"],data(){return{isImageLoading:!0,imageUrl:null}},watch:{"imageData.urls.regular":function(e){this.setImageUrlDebounced(e)},"imageData.blur_hash":{immediate:!0,handler(){this.isImageLoading=!0,this.drawBlurHash()}}},created(){window.addEventListener("keydown",this.handleKeyboardNavigation),this.setImageUrl(this.imageData.urls.regular)},unmounted(){window.removeEventListener("keydown",this.handleKeyboardNavigation)},methods:{handleKeyboardNavigation(t){if(He(t)===ce.ArrowLeft&&!this.isFirstImage){t.preventDefault(),this.$emit("show-previous-image");return}He(t)===ce.ArrowRight&&!this.isLastImage&&(t.preventDefault(),this.$emit("show-next-image"))},setImageUrlDebounced:Tl(function(e){this.setImageUrl(e)},250),setImageUrl(t){this.imageUrl=t},drawBlurHash(){const t=this.$refs.blurHashCanvas;if(!t)return;const o=this.getLimitedDimensions(32,this.imageData.width,this.imageData.height),n=Lx(this.imageData.blur_hash,o.width,o.height);t.width=o.width,t.height=o.height;const s=t.getContext("2d"),a=s.createImageData(o.width,o.height);a.data.set(n),s.putImageData(a,0,0)},getLimitedDimensions(t,e,o){if(e<=t)return{height:o,width:e};const n=e/t;return{height:Math.floor(o/n),width:t}}}}),MN=t=>(ke("data-v-e5c573ea"),t=t(),Ie(),t),HN={class:"unsplash-preview"},NN={class:"unsplash-preview__image-container"},GN={class:"unsplash-preview__blurhash"},FN={ref:"blurHashCanvas"},VN=["src","data-image-id","alt"],UN={class:"unsplash-preview__image-switcher"},jN={class:"accreditation"},WN={class:"accreditation__author"},qN=["src","alt"],YN={class:"accreditation__meta text-body-2"},KN=["href"],ZN=MN(()=>m("br",null,null,-1)),QN={class:"accreditation__tos text-body-2"},XN={class:"z-link",href:"https://unsplash.com/terms",target:"_blank",rel:"noopener noreferrer"};function JN(t,e,o,n,s,a){const l=G("Icon"),i=G("HostingerButton"),r=G("i18n-t"),u=ct("qa");return d(),v("div",HN,[m("div",NN,[O(m("div",GN,[m("canvas",FN,null,512)],512),[[Qe,t.isImageLoading]]),O(m("img",{class:"unsplash-preview__image",src:t.imageUrl,"data-image-id":t.imageData.id,alt:t.imageData.alt_description,onLoad:e[0]||(e[0]=p=>(t.isImageLoading=!1,t.$emit("image-loaded",t.imageUrl)))},null,40,VN),[[Qe,!t.isImageLoading],[u,"chooseimage-preview-unsplashimage"]]),m("div",UN,[h(i,{"button-type":"plain",theme:"highlight",disabled:t.isFirstImage,title:"prev",onClick:e[1]||(e[1]=p=>t.$emit("show-previous-image"))},{icon:_(()=>[h(l,{name:"chevron_left"})]),_:1},8,["disabled"]),h(i,{"button-type":"plain",theme:"highlight",title:"next",disabled:t.isLastImage,onClick:e[2]||(e[2]=p=>t.$emit("show-next-image"))},{icon:_(()=>[h(l,{name:"chevron_right"})]),_:1},8,["disabled"])])]),m("div",jN,[m("div",WN,[m("img",{class:"accreditation__avatar",src:t.imageData.user.profile_image.small,alt:`${t.imageData.user.name} unsplash profile image`},null,8,qN),m("span",YN,[j(w(t.$t("builder.assetManagerTabUnsplashBy"))+" ",1),m("a",{class:"accreditation__link",target:"_blank",href:`https://unsplash.com/@${t.imageData.user.username}?utm_source=builder&utm_medium=referral`},w(t.imageData.user.name),9,KN),ZN,j(" "+w(t.imageData.width)+" × "+w(t.imageData.height),1)])]),m("span",QN,[h(r,{keypath:"builder.assetManagerTabUnsplashAccreditation"},{default:_(()=>[m("a",XN,w(t.$t("builder.assetManagerTabUnsplashAccreditationLink")),1)]),_:1})]),O((d(),S(i,{onClick:e[3]||(e[3]=p=>t.$emit("select-image",t.imageData))},{default:_(()=>[j(w(t.isGallery?t.$t("builder.assetManagerAddToGallery"):t.$t("builder.assetManagerAddToPage")),1)]),_:1})),[[u,"chooseimage-btn-addtopage"]])])])}const tG=H(RN,[["render",JN],["__scopeId","data-v-e5c573ea"]]),rI="https://builder-backend.hostinger.com/unsplash",S_=async({query:t,page:e,count:o})=>{const{data:n}=await Ut.post(`${rI}/search`,{query:t,page:e,count:o});return n.response||n},eG=({imageJson:t})=>{try{Ut.post(`${rI}/download/`,{imageJson:t},{common:{"Content-Type":"application/json"}})}catch(e){console.error(e)}},oG={class:"grid-gallery-masonry"},Sf=q({__name:"Masonry",props:{images:{},columnCount:{},columnGap:{}},setup(t){ue(s=>({"03f6e6b0":e.columnCount,"0b640746":o.value}));const e=t,o=c(()=>`${e.columnGap}px`),n=c(()=>e.images.reduce((s,a,l)=>s.map((i,r)=>r===l%e.columnCount?[...i,{...a,originalIndex:l}]:i),Array(e.columnCount).fill([])));return(s,a)=>(d(),v("div",oG,[(d(!0),v(dt,null,zt(n.value,(l,i)=>(d(),v("div",{key:i,class:"grid-gallery-masonry__column"},[(d(!0),v(dt,null,zt(l,r=>vt(s.$slots,"image",{index:r.originalIndex,image:r})),256))]))),128))]))}}),nG=q({name:"UnsplashLayout",components:{ZyroInput:bs,ZyroSvgDeprecated:qt,ZyroLoader:Ue,UnsplashPreview:tG,Masonry:Sf},props:{isPreviewOpen:{type:Boolean,required:!0},isGallery:{type:Boolean,default:!1}},emits:["toggle-preview","select-image"],setup(){const{notify:t}=Le();return{notify:t}},data(){return{loadedThumbnails:[],isSearchRequestPending:!1,isNewSearchRequestPending:!1,previewImageIndex:-1,unsplashResponse:{results:dH.map(t=>{const e=`${h9}/${t.id}.jpeg`;return{...t,urls:{raw:e,regular:jo("other",e,this.websiteId,{width:1080}),thumb:jo("other",e,this.websiteId,{width:280})}}})},searchTerm:"",scrollTop:0,currentPage:0}},computed:{...Ae(["websiteId"]),unsplashResultsFiltered(){var t,e,o,n;return(t=this.unsplashResponse)!=null&&t.results?((n=(o=(e=this.unsplashResponse)==null?void 0:e.results)==null?void 0:o.errors)==null?void 0:n.length)>0?(this.notify({messageI18nKeyPath:"builder.errorWhileLoadingUnsplashImage"}),[]):this.unsplashResponse.results.map(s=>({urls:s.urls,id:s.id,user:s.user,width:s.width,height:s.height,blur_hash:s.blur_hash,alt_description:s.alt_description,links:s.links})):[]},previewImage(){return this.isPreviewOpen?this.unsplashResultsFiltered[this.previewImageIndex]:null}},watch:{async isPreviewOpen(t){t||(await this.$nextTick(),this.$refs.unsplashContainer.scrollTo(0,this.scrollTop))}},methods:{startUnsplashSearch:Tl(async function(){if(this.searchTerm){this.unsplashResponse.results=[],this.loadedThumbnails=[],this.currentPage=1,this.isNewSearchRequestPending=!0;try{this.searchTerm.length>2&&Et.logEvent({eventName:"website_builder.asset_manager.image_search",eventProperties:{phrase:this.searchTerm}}),this.unsplashResponse=await S_({query:this.searchTerm,page:this.currentPage})}catch(e){this.notify({messageI18nKeyPath:"builder.errorWhileSearchingImages"}),jt(e)}finally{this.isNewSearchRequestPending=!1}}},1e3),async loadMoreFromUnsplash(t=!1){const{unsplashContainer:e}=this.$refs;if(!e)return;this.scrollTop=e.scrollTop;const n=e.offsetHeight+this.scrollTop+1400>(e==null?void 0:e.scrollHeight);if(!(!this.searchTerm||this.unsplashResponse.total_pages<=this.currentPage||this.isSearchRequestPending||!n&&!t||this.loadedThumbnails.length=this.unsplashResultsFiltered.length-2&&this.loadMoreFromUnsplash(!0),this.$emit("toggle-preview",t!==-1)}}}),iG={class:"unsplash__wrapper"},sG={key:0,class:"unsplash__no-results"},aG={class:"text-heading-1"},lG={class:"text-body-2 unsplash__no-results-bottom-text"},rG=["src","onClick","onLoad"],dG={key:2,class:"loader-wrapper"},cG={class:"unsplash__bottom-bar"};function uG(t,e,o,n,s,a){const l=G("UnsplashPreview"),i=G("ZyroInput"),r=G("ZyroSvgDeprecated"),u=G("i18n-t"),p=G("Masonry"),g=G("ZyroLoader"),b=ct("qa");return d(),v("div",{class:rt(["unsplash",{"unsplash--preview-open":t.isPreviewOpen}])},[t.isPreviewOpen?(d(),S(l,{key:0,"image-data":t.previewImage,"is-last-image":t.previewImageIndex===t.unsplashResultsFiltered.length-1,"is-first-image":t.previewImageIndex===0,"is-gallery":t.isGallery,onShowPreviousImage:t.decreasePreviewImageIndex,onShowNextImage:t.increasePreviewImageIndex,onSelectImage:e[0]||(e[0]=y=>t.$emit("select-image",y))},null,8,["image-data","is-last-image","is-first-image","is-gallery","onShowPreviousImage","onShowNextImage"])):B("",!0),O(m("div",iG,[h(i,{modelValue:t.searchTerm,"onUpdate:modelValue":[e[1]||(e[1]=y=>t.searchTerm=y),t.startUnsplashSearch],"qa-selector":"chooseimage-inputfield-searchforphotos",class:"unsplash__search-input",placeholder:t.$t("builder.assetManagerTabUnsplashSearch")},null,8,["modelValue","placeholder","onUpdate:modelValue"]),m("div",{ref:"unsplashContainer",class:"unsplash__container",onScrollPassive:e[2]||(e[2]=(...y)=>t.loadMoreFromUnsplash&&t.loadMoreFromUnsplash(...y))},[!t.isNewSearchRequestPending&&!t.unsplashResultsFiltered.length?O((d(),v("div",sG,[h(r,{name:"sad-face"}),m("span",aG,[h(u,{keypath:"builder.assetManagerTabUnsplashNoResults"},{default:_(()=>[j(w(t.searchTerm),1)]),_:1})]),m("span",lG,w(t.$t("builder.assetManagerTabUnsplashCheckSpelling")),1)])),[[b,"chooseimage-section-noresults"]]):t.unsplashResultsFiltered.length?O((d(),S(p,{key:1,images:t.unsplashResultsFiltered,"column-count":t.isMobileScreen?2:4,"column-gap":4},{image:_(({image:y,index:k})=>[O(m("img",{class:"unsplash__image",src:y.urls.thumb,onClick:I=>t.setPreviewImageIndex(k),onLoad:I=>t.loadedThumbnails.push(y.id)},null,40,rG),[[b,"chooseimage-unsplashimage"]])]),_:1},8,["images","column-count"])),[[b,"chooseimage-section-freeimages"]]):B("",!0),t.isSearchRequestPending||t.isNewSearchRequestPending?(d(),v("div",dG,[O(h(g,null,null,512),[[b,"builder-loader"]])])):B("",!0)],544),m("div",cG,[h(r,{name:"unsplash"})])],512),[[Qe,!t.isPreviewOpen]])],2)}const pG=H(nG,[["render",uG],["__scopeId","data-v-0aa48ddb"]]),dI=async t=>new Promise((e,o)=>{const n=new Image;n.addEventListener("load",()=>e(n)),n.addEventListener("error",s=>o(new Error("Failed to load image",s))),n.src=t}),gG=["id","checked"],mG=["for"],hG=q({__name:"ZyroCheckbox",props:{modelValue:{type:Boolean},id:{default:""},theme:{default:"purple"},isRounded:{type:Boolean},isFilled:{type:Boolean},isNonClickable:{type:Boolean}},emits:["update:model-value"],setup(t,{emit:e}){const o=t,n=e,s=c(()=>o.id||ie()),a=l=>{o.isNonClickable||n("update:model-value",l.target.checked)};return(l,i)=>(d(),v("div",{class:rt(["zyro-checkbox",`zyro-checkbox--theme-${l.theme}`])},[m("input",{id:s.value,type:"checkbox",checked:l.modelValue,class:"zyro-checkbox__input",onInput:i[0]||(i[0]=r=>a(r))},null,40,gG),m("label",{for:s.value,class:rt(["zyro-checkbox__label",[{"zyro-checkbox__label--fully-rounded":l.isRounded},{"zyro-checkbox__label--filled":l.isFilled}]])},[h(qt,{class:"zyro-checkbox__check-mark",name:"check-mark-thick"})],10,mG)],2))}}),Vr=H(hG,[["__scopeId","data-v-a1d6318e"]]),bG=q({components:{SystemDialogModal:tn,ZyroCheckbox:Vr},emits:["close"],setup(t,e){const{isDeleteAssetModalOpened:o,isAssetBeingDeleted:n,deleteMediaAsset:s,assetsToDelete:a,folderToDelete:l,assets:i}=Ss(t,e),{t:r}=_t(),{deleteAssetFromFoldersData:u,deleteFolderFromFoldersData:p,assetPaths:g}=im({assets:i}),b=C(!1),y=c(()=>l.value?r("builder.foldersDeleteFolder"):r("builder.assetManagerTabUserDelete")),k=c(()=>{var T;return(T=My({directory:l.value.path,assets:i.value,assetPaths:g.value,includeFromSubfolders:!0}))==null?void 0:T.length}),I=()=>{o.value=!1,b.value=!1,l.value=null,a.value=[]};return{isDeleteAssetModalOpened:o,isAssetBeingDeleted:n,handleDeleteAsset:async()=>{if(a.value.length&&await s(),l.value)p({path:l.value.path});else{const T=Ia(a.value[0].url);await u({id:T})}I()},resetDialogStates:I,folderToDelete:l,isSelected:b,modalTitle:y,directoryToDeleteFileCount:k}}}),fG=t=>(ke("data-v-b1a06b33"),t=t(),Ie(),t),yG={class:"delete-dialog__checkbox-wrapper"},vG=fG(()=>m("br",null,null,-1));function _G(t,e,o,n,s,a){const l=G("i18n-t"),i=G("ZyroCheckbox"),r=G("SystemDialogModal"),u=ct("qa");return t.isDeleteAssetModalOpened?(d(),S(r,{key:0,"is-loading":t.isAssetBeingDeleted,title:t.modalTitle,"primary-button-text":t.$t("common.cancel"),"secondary-button-text":t.$t("common.delete"),"secondary-button-color":"danger","is-button-disabled":t.folderToDelete&&!t.isSelected,class:"delete-dialog",onClose:t.resetDialogStates,onClickPrimary:t.resetDialogStates,onClickSecondary:t.handleDeleteAsset},{default:_(()=>[t.folderToDelete?(d(),v(dt,{key:0},[h(l,{keypath:"builder.foldersDeleteMessage",tag:"p"},{default:_(()=>[m("b",null,w(t.$t("builder.foldersDeleteMessageSlot",t.directoryToDeleteFileCount,{count:t.directoryToDeleteFileCount})),1)]),_:1}),m("div",yG,[O(h(i,{"is-filled":"","model-value":t.isSelected,"onUpdate:modelValue":e[0]||(e[0]=p=>t.isSelected=!t.isSelected)},null,8,["model-value"]),[[u,"asset-delete-dialog-folder-checkbox"]]),m("p",{class:"text-body-2 delete-dialog__checkbox-label",onClick:e[1]||(e[1]=p=>t.isSelected=!t.isSelected)},w(t.$t("builder.foldersDeleteConfirmation")),1)])],64)):(d(),v(dt,{key:1},[j(w(t.$t("builder.assetManagerDialogAreYouSure")),1),vG,m("b",null,w(t.$t("builder.assetManagerDialogImageRemoveFromSite")),1)],64))]),_:1},8,["is-loading","title","primary-button-text","secondary-button-text","is-button-disabled","onClose","onClickPrimary","onClickSecondary"])):B("",!0)}const cI=H(bG,[["render",_G],["__scopeId","data-v-b1a06b33"]]),wG={class:"go-back-button"},kG={class:"go-back-button__text"},IG={__name:"AssetManagerGoBackButton",emits:["button-click"],setup(t){return(e,o)=>(d(),v("div",wG,[h(ut,{"button-type":"text",class:"go-back-button__button text-body-1",onClick:o[0]||(o[0]=n=>e.$emit("button-click"))},{"icon-left":_(()=>[h(lt,{name:"arrow_back"})]),default:_(()=>[m("span",kG,w(e.$t("builder.assetManagerMediaLayoutGoBack")),1)]),_:1})]))}},uI=H(IG,[["__scopeId","data-v-b038f670"]]),SG=q({props:{topic:{type:String,required:!0},subtopic:{type:String,required:!0}}}),EG={class:"assets-layout-item"},xG={class:"assets-layout-item__image-detail-topic"},TG={class:"assets-layout-item__image-detail-subtopic"};function CG(t,e,o,n,s,a){return d(),v("div",EG,[m("p",xG,w(t.topic),1),m("p",TG,w(t.subtopic),1)])}const PG=H(SG,[["render",CG],["__scopeId","data-v-993281fa"]]),jy=q({components:{Icon:lt,HostingerButton:ut,ZyroSeparator:ye,ZyroSvgDeprecated:qt,ZyroFieldInput:Ge,AssetDeleteDialog:cI,AssetsLayoutItem:PG,AssetManagerGoBackButton:uI},props:{asset:{type:Object,required:!0},isAssetSelectButtonHidden:{type:Boolean,default:!1}},emits:["close","select-image","update-img-alt-tag","select-asset"],setup(t,e){const{assets:o,isDeleteAssetModalOpened:n,isAssetBeingDeleted:s,assetsToDelete:a,updateUsedImageAltTag:l}=Ss(t,e),i=C(!1),r=C(t.asset.altTag||"");return{isAltTagSaveButtonShown:i,isDeleteAssetModalOpened:n,isAssetBeingDeleted:s,assets:o,assetAltTag:r,saveAltTag:()=>{e.emit("update-img-alt-tag",{asset:t.asset,newAltTag:r.value}),l({asset:t.asset,newAltTag:r.value}),i.value=!1},isAssetCategoryImage:cs,handleDeleteClick:()=>{a.value=[t.asset],n.value||(n.value=!0)},updateImgAltTag:b=>{r.value=b,i.value=!0}}},data(){return{imageWidth:"-",imageHeight:"-"}},computed:{...Ae(["websiteId"]),imageBackdropUrl(){return`url(${ir("/assets/images/image-backdrop.png")})`},assetExtension(){return this.asset.url?En(this.asset.url):this.$t("builder.assetManagerMediaLayoutDetailTabExtensionUndefined")}},methods:{async updateImageDimensions(){var o,n;const{naturalWidth:t,naturalHeight:e}=await dI(this.asset.url);this.imageWidth=t||((o=this.asset)==null?void 0:o.width),this.imageHeight=e||((n=this.asset)==null?void 0:n.height)}}}),E_=()=>{ue(t=>({"49ee4cec":t.imageBackdropUrl}))},x_=jy.setup;jy.setup=x_?(t,e)=>(E_(),x_(t,e)):E_;const BG={class:"asset-details-layout"},AG={class:"asset-details-layout__content"},DG=["src"],zG={class:"asset-details-layout__image-details"},$G={class:"asset-details-layout__alt-sublabel"},LG={class:"asset-details-layout__alt-save-button"};function OG(t,e,o,n,s,a){const l=G("AssetManagerGoBackButton"),i=G("HostingerButton"),r=G("ZyroSvgDeprecated"),u=G("AssetsLayoutItem"),p=G("ZyroFieldInput"),g=G("ZyroSeparator"),b=G("Icon"),y=G("AssetDeleteDialog"),k=ct("qa");return d(),v("div",BG,[h(l,{onButtonClick:e[0]||(e[0]=I=>t.$emit("close"))}),m("div",AG,[m("div",{class:rt(["asset-details-layout__image-container",{"asset-details-layout__image-container--boxed-grid":t.isAssetCategoryImage(t.asset)}])},[t.isAssetCategoryImage(t.asset)?(d(),v(dt,{key:0},[m("img",{ref:"image",src:t.asset.urlBase64?t.asset.urlBase64:t.asset.url,class:"asset-details-layout__image",onLoad:e[1]||(e[1]=(...I)=>t.updateImageDimensions&&t.updateImageDimensions(...I))},null,40,DG),t.isAssetSelectButtonHidden?B("",!0):(d(),S(i,{key:0,title:t.$t("builder.assetManagerMediaLayoutSelectItem"),class:"asset-details-layout__button-select-item",onClick:e[2]||(e[2]=I=>t.$emit("select-asset",t.asset.url))},{default:_(()=>[j(w(t.$t("builder.assetManagerMediaLayoutSelectItem")),1)]),_:1},8,["title"]))],64)):(d(),S(r,{key:1,name:"file"}))],2),m("div",zG,[m("div",null,[h(u,{topic:t.$t("builder.assetManagerMediaLayoutDetailTabFileName"),subtopic:t.asset.name,class:"asset-details-layout__assets-layout-item"},null,8,["topic","subtopic"]),h(u,{topic:t.$t("builder.assetManagerMediaLayoutDetailTabExtension"),subtopic:t.assetExtension,class:"asset-details-layout__assets-layout-item"},null,8,["topic","subtopic"]),h(u,{topic:t.$t("builder.assetManagerMediaLayoutDetailTabPath"),subtopic:t.asset.url,class:"asset-details-layout__assets-layout-item"},null,8,["topic","subtopic"]),t.isAssetCategoryImage(t.asset)?(d(),S(u,{key:0,topic:t.$t("builder.assetManagerMediaLayoutDetailTabDimensions"),subtopic:`${t.imageWidth} x ${t.imageHeight} ${t.$t("builder.assetManagerMediaLayoutPixels")}`,class:"asset-details-layout__assets-layout-item"},null,8,["topic","subtopic"])):B("",!0),t.isAssetCategoryImage(t.asset)?(d(),S(p,{key:1,label:t.$t("builder.editImage.tabSeo.textFieldLabel"),"model-value":t.assetAltTag,class:rt(["asset-details-layout__alt-input",{"asset-details-layout__alt-input--save":t.isAltTagSaveButtonShown}]),"qa-selector":"img-alt-text-input",maxlength:"125","onUpdate:modelValue":t.updateImgAltTag},{sublabel:_(()=>[m("p",$G,w(t.$t("builder.editImage.tabSeo.label")),1)]),suffix:_(()=>[m("span",LG,[t.isAltTagSaveButtonShown?(d(),S(i,{key:0,"button-type":"plain",onClick:t.saveAltTag},{default:_(()=>[j(w(t.$t("common.save")),1)]),_:1},8,["onClick"])):B("",!0)])]),_:1},8,["label","model-value","class","onUpdate:modelValue"])):B("",!0),h(g,{class:"asset-details-layout__separator"}),O((d(),S(i,{"button-type":"outlined",theme:"danger",onClick:t.handleDeleteClick},{"icon-left":_(()=>[h(b,{name:"delete"})]),default:_(()=>[j(" "+w(t.$t("builder.assetManagerMediaLayoutDeleteThisItem")),1)]),_:1},8,["onClick"])),[[k,"asset-delete-btn"]])])])]),h(y,{onClose:e[3]||(e[3]=I=>t.$emit("close"))})])}const RG=H(jy,[["render",OG],["__scopeId","data-v-44ef9a5b"]]),MG={class:"control-buttons"},HG={class:"control-buttons__button-text"},NG={class:"control-buttons__button-text"},GG={class:"control-buttons__button-text"},FG={class:"control-buttons__button-text control-buttons__button-text--folders"},VG=["onClick"],UG={class:"control-buttons__button-text control-buttons__button-text--folders"},jG={__name:"AssetControls",props:{isFolder:{type:Boolean,default:!1},currentTab:{type:Object,default:null}},emits:["rename-asset","delete-asset","move-asset-to"],setup(t,{emit:e}){const o=t,n=e,{getters:s}=nt(),{isDeleteAssetModalOpened:a,assets:l}=Ss(),{folders:i}=im({assets:l}),r=C(!1),u=C(!1),p=C(!1),g=C(!1),b=c(()=>o.currentTab&&o.currentTab.id===Oo.MY_LIBRARY),y=c(()=>i.value.length),k=c(()=>!o.isFolder&&y.value&&b.value),I=c(()=>s["assets/currentDirectory"]),E=c(()=>i.value.find(D=>D.path===I.value)),T=c(()=>i.value.filter(D=>D.path!==I.value)),P=()=>{p.value=!1,g.value=!1,a.value=!1},z=()=>{p.value=!1,n("delete-asset")},L=()=>{p.value=!1,n("rename-asset")};return(D,$)=>{var M;const A=ct("qa");return d(),v(dt,null,[h(ut,gn(D.$attrs,{ref_key:"assetSettingsRef",ref:r,"button-type":"plain",theme:"highlight",onClick:$[0]||($[0]=U=>p.value=!p.value)}),{icon:_(()=>[O(h(lt,{name:"more_vert",dimensions:"20px"},null,512),[[A,t.isFolder?"more-options-folder":"more-options-asset"]])]),_:1},16),p.value?(d(),S(ve,{key:0,"target-ref":(M=r.value)==null?void 0:M.$el,placement:"right-end","portal-selector":f($1),"auto-update":"","is-only-click-inside":"",onClickOutside:P},{default:_(()=>[m("div",MG,[k.value?O((d(),v("button",{key:0,ref_key:"moveToButtonRef",ref:u,class:"control-buttons__button z-button-small",onMouseenter:$[1]||($[1]=U=>g.value=!0)},[h(qt,{dimensions:"16px",name:"folder-move"}),m("span",HG,w(D.$t("builder.foldersMoveTo")),1),h(qt,{dimensions:"18px",name:"chevron-right"})],32)),[[A,"asset-controls-button-move"]]):B("",!0),O((d(),v("button",{class:"control-buttons__button z-button-small",onClick:L,onMouseenter:$[2]||($[2]=U=>g.value=!1)},[h(qt,{name:"type"}),m("span",NG,w(D.$t("common.rename")),1)],32)),[[A,"asset-controls-button-rename"]]),O((d(),v("button",{theme:"plain",class:"control-buttons__button z-button-small",onClick:z},[h(qt,{name:"trash"}),m("span",GG,w(D.$t("common.delete")),1)])),[[A,"asset-controls-button-delete"]])]),g.value?(d(),S(ve,{key:0,"target-ref":u.value,placement:"right-start",offset:12,"auto-update":"","is-only-click-inside":"","portal-selector":f($1),onClickOutside:$[5]||($[5]=U=>k.value=!1)},{default:_(()=>[m("div",{class:"control-buttons",onMouseleave:$[4]||($[4]=U=>g.value=!1)},[E.value?(d(),v("button",{key:0,class:rt(["z-button-small control-buttons__button",{"control-buttons__button--underlined":T.value.length}]),onClick:$[3]||($[3]=U=>D.$emit("move-asset-to","/"))},[h(qt,{name:"folder-outline"}),m("span",FG,w(D.$t("builder.foldersMyLibrary")),1)],2)):B("",!0),(d(!0),v(dt,null,zt(T.value,U=>O((d(),v("button",{key:U.name,class:"control-buttons__button z-button-small",onClick:Y=>D.$emit("move-asset-to",U.path)},[h(qt,{name:"folder-outline"}),m("span",UG,w(U.name),1)],8,VG)),[[A,`asset-controls-moving-folders-${U.name}`]])),128))],32)]),_:1},8,["target-ref","portal-selector"])):B("",!0)]),_:1},8,["target-ref","portal-selector"])):B("",!0)],64)}}},pI=H(jG,[["__scopeId","data-v-1490c170"]]),WG=q({props:{assetName:{type:String,default:""}},emits:["toggle-input"],setup(t,e){const o=C(null),n=C(null),s=C(t.assetName),a=()=>{const i=s.value.replace(/[^\d -_a-z]/gi,"").trim();s.value=i,e.emit("toggle-input",i)},l=i=>{i.target.setCustomValidity(""),s.value=i.target.value};return ia({target:n},()=>{o.value.reportValidity()&&a()}),{formRef:o,nameInputRef:n,handleRenameAsset:a,handleNameInput:l}}}),qG=["value"];function YG(t,e,o,n,s,a){return d(),v("form",{ref:"formRef",onSubmit:e[2]||(e[2]=Yt((...l)=>t.handleRenameAsset&&t.handleRenameAsset(...l),["prevent"]))},[m("input",{ref:"nameInputRef",type:"text",value:t.assetName,class:"asset-name-input text-body-2",pattern:"^([a-zA-Z0-9- _()]+)$",onInvalid:e[0]||(e[0]=l=>l.target.setCustomValidity(t.$t("builder.foldersAllowedCharacters",{chars:"A-Z, a-z, 0-9, _-()"}))),onInput:e[1]||(e[1]=(...l)=>t.handleNameInput&&t.handleNameInput(...l))},null,40,qG)],544)}const gI=H(WG,[["render",YG],["__scopeId","data-v-b797f288"]]),Wy=q({components:{HostingerButton:ut,ZyroCheckbox:Vr,ZyroSvgDeprecated:qt,UploadLoader:nI,AssetControls:pI,AssetNameInput:gI},props:{asset:{type:Object,required:!0},isGallery:{type:Boolean,default:!1},currentTab:{type:Object,required:!0},isAssetSelectButtonHidden:{type:Boolean,default:!1}},emits:["select","open-image-details","move-asset-to","rename-asset","delete-asset"],setup(t,e){const{getters:o}=nt(),{toggleGalleryImageCheckbox:n,uploadingAssetCount:s}=Ss(),a=C(!1),l=c(()=>o["assets/assetPaths"]),i=c(()=>Object.values(l.value).some(b=>b.path===t.asset.path)),r=c(()=>t.asset.name),u=c(()=>!!s.value>0&&!i.value),p=`url(${ir("/assets/images/image-backdrop.png")})`;return{toggleGalleryImageCheckbox:n,isAssetCategoryImage:cs,isAssetBeingRenamed:a,isAssetBeingUploaded:u,assetName:r,toggleInput:b=>{e.emit("rename-asset",b),a.value=!a.value},imageBackdropUrl:p}},data(){return{isReadyToBeShown:!1}},computed:{...Ae(["websiteId"]),optimizedImageUrl(){return this.isAssetCategoryImage(this.asset)?Hr(this.asset.url)?this.asset.url:jo("assets",Ia(this.asset.url),this.websiteId,{width:j0}):this.asset.url},isLoading(){return(this.asset.transferProgress!==100||!this.isReadyToBeShown)&&!this.asset.isFetchedFromServer}},watch:{"asset.transferProgress":function(e){e===100&&setTimeout(()=>{this.isReadyToBeShown=!0},2e3)}},created(){this.isReadyToBeShown=this.asset.transferProgress===100},methods:{getFileNameFromURL:Ia,getExtension:En}}),T_=()=>{ue(t=>({"03c34b34":t.imageBackdropUrl}))},C_=Wy.setup;Wy.setup=C_?(t,e)=>(T_(),C_(t,e)):T_;const qy=t=>(ke("data-v-b1ffc99f"),t=t(),Ie(),t),KG=["data-qa"],ZG={key:0},QG={class:"asset-thumbnail__loader-image"},XG={key:0,class:"asset-thumbnail__checkmark-icon-container"},JG=qy(()=>m("div",{class:"asset-thumbnail__loader-name"},null,-1)),tF=qy(()=>m("div",{class:"asset-thumbnail__loader-description"},null,-1)),eF={key:1},oF=["src"],nF=qy(()=>m("div",{class:"asset-thumbnail__hover-backdrop"},null,-1)),iF={class:"asset-thumbnail__data-wrapper"},sF={class:"asset-thumbnail__text-wrapper"},aF=["title"],lF={class:"asset-thumbnail__description text-body-2"};function rF(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated"),i=G("UploadLoader"),r=G("HostingerButton"),u=G("ZyroCheckbox"),p=G("AssetNameInput"),g=G("AssetControls"),b=ct("qa");return d(),v("div",{class:rt(["asset-thumbnail",{"asset-thumbnail--placeholder":t.asset.type==="placeholder"}]),"data-qa":`asset-thumbnail-${t.asset.id}`},[t.isLoading?(d(),v("div",ZG,[m("div",QG,[t.asset.transferProgress===100?(d(),v("div",XG,[h(l,{name:"check-mark-blue"})])):B("",!0),h(i,{class:"user-image__loader-svg",progress:t.asset.transferProgress},null,8,["progress"])]),JG,tF])):(d(),v("div",eF,[O((d(),v("div",{class:rt(["asset-thumbnail__thumbnail-container",{"asset-thumbnail__thumbnail-container--boxed-grid":t.isAssetCategoryImage(t.asset)}]),onClick:e[2]||(e[2]=y=>t.$emit("select"))},[t.isAssetCategoryImage(t.asset)?(d(),v("img",{key:0,ref:"image",loading:"lazy",src:t.asset.urlBase64?t.asset.urlBase64:t.optimizedImageUrl,class:"asset-thumbnail__thumbnail"},null,8,oF)):(d(),S(l,{key:1,class:"asset-thumbnail__document-icon",name:"file-small"})),t.asset.url&&!t.isAssetSelectButtonHidden?O((d(),S(r,{key:2,class:"asset-thumbnail__add-to-page-button",onClick:e[0]||(e[0]=Yt(y=>t.$emit("select"),["stop"]))},{default:_(()=>[j(w(t.$t("builder.assetManagerSelectAsset")),1)]),_:1})),[[b,`asset-thumbnail-select-button-${t.assetName}`]]):B("",!0),nF,O((d(),v("button",{class:"asset-thumbnail__details-button",onClick:e[1]||(e[1]=Yt(y=>t.$emit("open-image-details"),["stop"]))},[j(w(t.$t("builder.assetManagerThumbnailDetails")),1)])),[[b,`asset-thumbnail-details-button-${t.assetName}`]])],2)),[[b,`asset-thumbnail-container-${t.assetName}`]]),t.isGallery&&!t.isAssetSelectButtonHidden?(d(),S(u,{key:0,class:"asset-thumbnail__gallery-checkbox","model-value":t.asset.isGalleryImageSelected,theme:"blue","onUpdate:modelValue":e[3]||(e[3]=y=>t.toggleGalleryImageCheckbox(t.asset.id))},null,8,["model-value"])):B("",!0),m("div",iF,[m("div",sF,[t.isAssetBeingRenamed?(d(),S(p,{key:0,"asset-name":t.assetName,onToggleInput:t.toggleInput},null,8,["asset-name","onToggleInput"])):(d(),v("p",{key:1,class:"asset-thumbnail__name text-body-2",title:t.assetName},w(t.assetName),9,aF)),m("p",lF,w(t.asset.url?t.getExtension(t.asset.url).toUpperCase():"-"),1)]),h(g,{disabled:t.isAssetBeingUploaded,"current-tab":t.currentTab,onRenameAsset:e[4]||(e[4]=y=>t.isAssetBeingRenamed=!t.isAssetBeingRenamed),onDeleteAsset:e[5]||(e[5]=y=>t.$emit("delete-asset")),onMoveAssetTo:e[6]||(e[6]=y=>t.$emit("move-asset-to",y))},null,8,["disabled","current-tab"])])]))],10,KG)}const dF=H(Wy,[["render",rF],["__scopeId","data-v-b1ffc99f"]]);function cF({wrapperRef:t,mappedAssets:e}){const{width:o}=w5(t);return{dynamicallySegmentedAssets:c(()=>{if(!t.value)return[];const s=Math.floor(o.value/j0);return e.value.reduce((a,l,i)=>{const r=Math.floor(i/s),u=[...a];return u[r]=[...u[r]||[],l],u},[]).map((a,l,i)=>{if(l!==i.length-1||a.length===s)return a;const r=s-a.length;return[...a,...Array(r).fill({type:"placeholder"})]}).map((a,l)=>{const i=a;return i.id=String(l),i})})}}const uF={class:"assets-grid"},pF={class:"assets-grid__assets-row"},P_=260,B_=8,gF={__name:"AssetsGrid",props:{assets:{type:Array,required:!0},isGallery:{type:Boolean,default:!1},currentTab:{type:Object,required:!0},visibleCategories:{type:Array,default:()=>cc,validator:t=>t.every(e=>cc.includes(e))},isAssetSelectButtonHidden:{type:Boolean,default:!1}},emits:["open-image-details","select-image","move-asset-to","rename-asset","delete-asset"],setup(t){ue(i=>({"0fcf3ac6":P_,"65314d12":B_}));const e=t,o=C(),n=({assetCategory:i})=>{const r=e.visibleCategories.includes(Bo.DOCUMENT),u=e.visibleCategories.includes(Bo.IMAGE);return r?u?!1:i===Bo.IMAGE:i===Bo.DOCUMENT},s=c(()=>e.assets.map(i=>{const r=n({assetCategory:i.category});return{...i,isCategoryDifferentFromView:r}})),{dynamicallySegmentedAssets:a}=cF({mappedAssets:s,wrapperRef:o}),l=P_+B_;return(i,r)=>(d(),v("div",uF,[m("div",{ref_key:"wrapperRef",ref:o,class:"assets-grid__wrapper"},[h(f(Ox),{"page-mode":"",class:"scroller",items:f(a),"item-size":l,"key-field":"id"},{before:_(()=>[vt(i.$slots,"breadcrumbs",{},void 0,!0),vt(i.$slots,"folders",{},void 0,!0)]),default:_(({item:u})=>[m("div",pF,[(d(!0),v(dt,null,zt(u,p=>(d(),S(dF,{key:p.id,"is-asset-select-button-hidden":t.isAssetSelectButtonHidden||p.isCategoryDifferentFromView,asset:p,"is-gallery":t.isGallery,"current-tab":t.currentTab,onOpenImageDetails:g=>i.$emit("open-image-details",p),onSelect:g=>i.$emit("select-image",p.url),onMoveAssetTo:g=>i.$emit("move-asset-to",{newPath:g,asset:p}),onRenameAsset:g=>i.$emit("rename-asset",{asset:p,newName:g}),onDeleteAsset:g=>i.$emit("delete-asset",p)},null,8,["is-asset-select-button-hidden","asset","is-gallery","current-tab","onOpenImageDetails","onSelect","onMoveAssetTo","onRenameAsset","onDeleteAsset"]))),128))])]),_:3},8,["items"])],512)]))}},mF=H(gF,[["__scopeId","data-v-d833a6ec"]]),hF=q({components:{ZyroSvgDeprecated:qt,AssetControls:pI,AssetNameInput:gI},props:{folderName:{type:String,required:!0}},emits:["open-directory","rename-asset","delete-asset"],setup(t,e){const o=C(!1);return{nameInputRef:C(null),isAssetBeingRenamed:o,handleFolderClick:()=>{o.value||e.emit("open-directory")},toggleInput:l=>{e.emit("rename-asset",l),o.value=!o.value}}}}),bF={class:"folder-thumbnail"},fF=["title"],yF={key:2,class:"folder-thumbnail__hover-backdrop"};function vF(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated"),i=G("AssetNameInput"),r=G("AssetControls"),u=ct("qa");return O((d(),v("div",bF,[m("div",{class:"folder-thumbnail__content-wrapper",onClick:e[0]||(e[0]=(...p)=>t.handleFolderClick&&t.handleFolderClick(...p))},[m("div",null,[h(l,{class:"folder-thumbnail__icon",name:"folder",dimensions:"24px"})]),t.isAssetBeingRenamed?(d(),S(i,{key:0,ref:"nameInputRef","asset-name":t.folderName,class:"folder-thumbnail__name-input",onToggleInput:t.toggleInput},null,8,["asset-name","onToggleInput"])):(d(),v("p",{key:1,class:"folder-thumbnail__name text-body-2",title:t.folderName},w(t.folderName),9,fF)),t.isAssetBeingRenamed?B("",!0):(d(),v("div",yF))]),h(r,{"is-folder":"",onRenameAsset:e[1]||(e[1]=p=>t.isAssetBeingRenamed=!t.isAssetBeingRenamed),onDeleteAsset:e[2]||(e[2]=p=>t.$emit("delete-asset"))})])),[[u,`folder-thumbnail-${t.folderName}`]])}const _F=H(hF,[["render",vF],["__scopeId","data-v-8f5d9b89"]]),wF={},kF={class:"assets-grid"};function IF(t,e){return d(),v("div",kF,[vt(t.$slots,"default",{},void 0,!0)])}const SF=H(wF,[["render",IF],["__scopeId","data-v-dbe4845a"]]),EF=q({components:{FolderThumbnail:_F,AssetsGridWrapper:SF},props:{folders:{type:Array,required:!0}},emits:["open-directory","rename-asset","delete-asset"]});function xF(t,e,o,n,s,a){const l=G("FolderThumbnail"),i=G("AssetsGridWrapper");return d(),S(i,null,{default:_(()=>[(d(!0),v(dt,null,zt(t.folders,r=>(d(),S(l,{key:r.id,"folder-name":r.name,"is-folder":"",onOpenDirectory:u=>t.$emit("open-directory",r.path),onRenameAsset:u=>t.$emit("rename-asset",{asset:r,newName:u}),onDeleteAsset:u=>t.$emit("delete-asset",r)},null,8,["folder-name","onOpenDirectory","onRenameAsset","onDeleteAsset"]))),128))]),_:1})}const TF=H(EF,[["render",xF]]),CF=q({components:{Icon:lt,HostingerButton:ut},props:{selectedAssetsCount:{type:Number,required:!0}},emits:["add-to-gallery","deselect-all","select-all"]}),PF={class:"gallery-assets-controls"},BF={class:"gallery-assets-controls__left-controls"},AF={class:"text-body-2"};function DF(t,e,o,n,s,a){const l=G("Icon"),i=G("HostingerButton");return d(),v("div",PF,[m("div",BF,[m("p",AF,w(t.selectedAssetsCount)+" "+w(t.$t("builder.assetManagerGalleryControlsItemsSelected")),1),h(i,{class:"gallery-assets-controls__button","button-type":"text","icon-left":"deselect-all",onClick:e[0]||(e[0]=r=>t.$emit("deselect-all"))},{"icon-left":_(()=>[h(l,{name:"deselect"})]),default:_(()=>[j(" "+w(t.$t("builder.assetManagerGalleryControlsDeselectAll")),1)]),_:1}),h(i,{class:"gallery-assets-controls__button","button-type":"text",onClick:e[1]||(e[1]=r=>t.$emit("select-all"))},{"icon-left":_(()=>[h(l,{name:"select-all"})]),default:_(()=>[j(" "+w(t.$t("builder.assetManagerGalleryControlsSelectAll")),1)]),_:1})]),h(i,{class:"gallery-assets-controls__button",onClick:e[2]||(e[2]=r=>t.$emit("add-to-gallery"))},{default:_(()=>[j(w(t.$t("builder.assetManagerAddToGallery")),1)]),_:1})])}const zF=H(CF,[["render",DF],["__scopeId","data-v-70b9787e"]]),$F=q({components:{ZyroSvgDeprecated:qt},setup(){const{getters:t,dispatch:e}=nt(),o=c(()=>t["assets/folders"]),n=c(()=>[...o.value].sort((l,i)=>l.path.localeCompare(i.path)));return{currentDirectory:c(()=>t["assets/currentDirectory"]),setCurrentDirectory:l=>e("assets/setCurrentDirectory",l),folders:n}}}),LF={class:"asset-folder-breadcrumbs"},OF={key:0,class:"asset-folder-breadcrumbs__breadcrumb"},RF=["onClick"];function MF(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated"),i=ct("qa");return d(),v("div",LF,[O((d(),v("button",{class:rt(["asset-folder-breadcrumbs__button text-body-2",{"asset-folder-breadcrumbs__button--current":t.currentDirectory==="/"}]),onClick:e[0]||(e[0]=r=>t.setCurrentDirectory("/"))},[j(w(t.$t("builder.foldersMyLibrary")),1)],2)),[[i,"asset-folder-breadcrumbs-my-library"]]),(d(!0),v(dt,null,zt(t.folders,(r,u)=>(d(),v(dt,{key:u},[t.currentDirectory.startsWith(r.path)?(d(),v("div",OF,[h(l,{name:"chevron-right",dimensions:"20px",class:"asset-folder-breadcrumbs__icon"}),O((d(),v("button",{class:rt(["asset-folder-breadcrumbs__button text-body-2",{"asset-folder-breadcrumbs__button--current":r.path===t.currentDirectory}]),onClick:p=>t.setCurrentDirectory(r.path)},[j(w(r.name),1)],10,RF)),[[i,`asset-folder-breadcrumbs-${r.name}`]])])):B("",!0)],64))),128))])}const HF=H($F,[["render",MF],["__scopeId","data-v-809acc92"]]),NF=t=>(ke("data-v-62b8b639"),t=t(),Ie(),t),GF=NF(()=>m("br",null,null,-1)),FF=q({__name:"AssetsLayout",props:{isGallery:{type:Boolean,default:!0},validAssets:{default:()=>[]},currentTab:{},visibleCategories:{default:()=>cc},isAssetSelectButtonHidden:{type:Boolean}},emits:["open-image-details","select-image","open-directory","add-to-gallery","open-file-dialog","rename-asset","delete-asset","move-asset-to"],setup(t,{emit:e}){const o=t,n=e,{isDraggedOver:s,listenForDragAndDrop:a,deleteFailedAssets:l,invalidAssetsBeingUploaded:i,uploadAssets:r,removeInvalidAssetsBeingUploaded:u,retryFailedAssets:p,hasServerAssetsLoaded:g,selectAllGalleryImages:b,deselectSelectedGalleryImages:y,assets:k}=Ss(o,{emit:n}),{currentDirectoryValidAssets:I,currentDirectoryFolders:E,validAssetsWithPaths:T,folders:P}=im({assets:c(()=>o.validAssets)}),z=c(()=>o.validAssets.filter(N=>Hr(N.url))),L=C(null),{t:D}=_t(),$={title:D("builder.assetManagerDialogAssetTooLargeTitleMixed"),descriptionOne:D("builder.assetManagerDialogAssetTooLargeLineOneDescriptionMixed"),descriptionTwo:D("builder.assetManagerDialogAssetTooLargeLineTwoDescriptionMixed",[Yb,qb])},A={title:D("builder.assetManagerDialogAssetTooLargeTitleImage"),descriptionOne:D("builder.assetManagerDialogAssetTooLargeOneDescriptionImage"),descriptionTwo:D("builder.assetManagerDialogAssetTooLargeDescriptionImage",[Yb])},M={title:D("builder.assetManagerDialogAssetTooLargeTitleDocument"),descriptionOne:D("builder.assetManagerDialogAssetTooLargeOneDescriptionDocument"),descriptionTwo:D("builder.assetManagerDialogAssetTooLargeDescriptionDocument",[qb])},U=c(()=>o.currentTab.id===Oo.MY_LIBRARY?I.value:o.currentTab.id===Oo.AI_IMAGES?z.value:T.value),Y=c(()=>k.value.filter(et=>et.hasFailed&&et.isUnsupportedFormat).length?{title:D("builder.assetManagerDialogAssetUnsupportedFormat"),description:D("builder.assetManagerNotSupportedFileTypes",{types:V6.map(et=>`.${et.toUpperCase()}`).join(", ")})}:k.value.some(et=>et.hasFailed&&et.isDimensionsTooLarge)?{title:D("builder.assetManagerDialogAssetTooLargeTitleImage"),description:D("builder.assetManagerDialogAssetTooLargeDimension")}:{title:D("builder.assetManagerDialogSomethingWentWrong"),description:D("builder.assetManagerDialogSomeFailed")});Nt(()=>{a(L.value)});const F=c(()=>k.value.filter(N=>N.isGalleryImageSelected).length),W=c(()=>!k.value.length&&!P.value.length),V=c(()=>k.value.filter(X=>X.hasFailed).length>0),K=c(()=>{const N=i.value.map(({category:et})=>et);if(new Set(N).size>1)return $;switch(N[0]){case Bo.DOCUMENT:return M;case Bo.IMAGE:return A;default:return $}}),Z=()=>{u(),r(i.value)};return(N,X)=>(d(),v("div",{ref_key:"userLayoutRef",ref:L,class:rt(["assets-layout",{"assets-layout--content-centered":W.value,"assets-layout--content-shifted":F.value>0}])},[f(g)?W.value?B("",!0):(d(),S(mF,{key:1,assets:U.value,"is-gallery":N.isGallery,"current-tab":N.currentTab,"visible-categories":N.visibleCategories,"is-asset-select-button-hidden":N.isAssetSelectButtonHidden,onOpenImageDetails:X[3]||(X[3]=et=>n("open-image-details",et)),onSelectImage:X[4]||(X[4]=et=>n("select-image",et)),onMoveAssetTo:X[5]||(X[5]=et=>n("move-asset-to",et)),onRenameAsset:X[6]||(X[6]=et=>n("rename-asset",et)),onDeleteAsset:X[7]||(X[7]=et=>n("delete-asset",et))},si({_:2},[N.currentTab.id===f(Oo).MY_LIBRARY?{name:"breadcrumbs",fn:_(()=>[h(HF)]),key:"0"}:void 0,N.currentTab.id===f(Oo).MY_LIBRARY&&f(E).length?{name:"folders",fn:_(()=>[h(TF,{folders:f(E),onOpenDirectory:X[0]||(X[0]=et=>n("open-directory",et)),onRenameAsset:X[1]||(X[1]=et=>n("rename-asset",et)),onDeleteAsset:X[2]||(X[2]=et=>n("delete-asset",et))},null,8,["folders"])]),key:"1"}:void 0]),1032,["assets","is-gallery","current-tab","visible-categories","is-asset-select-button-hidden"])):(d(),S(Ue,{key:0})),F.value>0?(d(),S(zF,{key:2,"selected-assets-count":F.value,class:"assets-layout__gallery-assets-control",onSelectAll:f(b),onDeselectAll:f(y),onAddToGallery:X[8]||(X[8]=et=>n("add-to-gallery"))},null,8,["selected-assets-count","onSelectAll","onDeselectAll"])):B("",!0),(W.value||f(s))&&f(g)?(d(),S(Uy,{key:3,class:"assets-layout__drag-and-drop-overlay","is-dragged-over":f(s),onOpenFileDialog:X[9]||(X[9]=et=>n("open-file-dialog"))},null,8,["is-dragged-over"])):B("",!0),f(i).length?(d(),S(tn,{key:4,title:K.value.title,"primary-button-text":N.$t("builder.assetManagerDialogTooCancel"),"secondary-button-text":N.$t("builder.assetManagerDialogSkipUnsupported"),onClose:f(u),onClickPrimary:f(u),onClickSecondary:Z},{default:_(()=>[j(w(K.value.descriptionOne)+" ",1),GF,j(" "+w(K.value.descriptionTwo),1)]),_:1},8,["title","primary-button-text","secondary-button-text","onClose","onClickPrimary"])):V.value?(d(),S(tn,{key:5,title:Y.value.title,"primary-button-text":N.$t("builder.assetManagerDialogRetry"),"secondary-button-text":N.$t("builder.assetManagerDialogSkipUnsupported"),onClose:f(l),onClickPrimary:f(p),onClickSecondary:f(l)},{default:_(()=>[j(w(Y.value.description),1)]),_:1},8,["title","primary-button-text","secondary-button-text","onClose","onClickPrimary","onClickSecondary"])):B("",!0),h(cI)],2))}}),VF=H(FF,[["__scopeId","data-v-62b8b639"]]),uc=[{id:3571264,width:3840,height:2160,duration:33,full_res:null,tags:[],url:"https://www.pexels.com/video/drone-view-of-big-waves-rushing-to-the-shore-3571264/",image:"https://images.pexels.com/videos/3571264/free-video-3571264.jpg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:1498112,name:"Enrique Hoyos",url:"https://www.pexels.com/@enrique"},video_files:[{id:9326316,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:29.97,link:"https://videos.pexels.com/video-files/3571264/3571264-uhd_2560_1440_30fps.mp4"},{id:9326361,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:29.97,link:"https://videos.pexels.com/video-files/3571264/3571264-sd_640_360_30fps.mp4"},{id:9326423,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:29.97,link:"https://videos.pexels.com/video-files/3571264/3571264-sd_960_540_30fps.mp4"},{id:9326528,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:29.97,link:"https://videos.pexels.com/video-files/3571264/3571264-uhd_3840_2160_30fps.mp4"},{id:9326609,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:29.97,link:"https://videos.pexels.com/video-files/3571264/3571264-sd_426_240_30fps.mp4"},{id:9326703,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:29.97,link:"https://videos.pexels.com/video-files/3571264/3571264-hd_1280_720_30fps.mp4"},{id:9326816,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:29.97,link:"https://videos.pexels.com/video-files/3571264/3571264-hd_1920_1080_30fps.mp4"}],video_pictures:[{id:815098,nr:0,picture:"https://images.pexels.com/videos/3571264/pictures/preview-0.jpg"},{id:815099,nr:1,picture:"https://images.pexels.com/videos/3571264/pictures/preview-1.jpg"},{id:815100,nr:2,picture:"https://images.pexels.com/videos/3571264/pictures/preview-2.jpg"},{id:815101,nr:3,picture:"https://images.pexels.com/videos/3571264/pictures/preview-3.jpg"},{id:815102,nr:4,picture:"https://images.pexels.com/videos/3571264/pictures/preview-4.jpg"},{id:815103,nr:5,picture:"https://images.pexels.com/videos/3571264/pictures/preview-5.jpg"},{id:815104,nr:6,picture:"https://images.pexels.com/videos/3571264/pictures/preview-6.jpg"},{id:815105,nr:7,picture:"https://images.pexels.com/videos/3571264/pictures/preview-7.jpg"},{id:815106,nr:8,picture:"https://images.pexels.com/videos/3571264/pictures/preview-8.jpg"},{id:815107,nr:9,picture:"https://images.pexels.com/videos/3571264/pictures/preview-9.jpg"},{id:815108,nr:10,picture:"https://images.pexels.com/videos/3571264/pictures/preview-10.jpg"},{id:815109,nr:11,picture:"https://images.pexels.com/videos/3571264/pictures/preview-11.jpg"},{id:815110,nr:12,picture:"https://images.pexels.com/videos/3571264/pictures/preview-12.jpg"},{id:815111,nr:13,picture:"https://images.pexels.com/videos/3571264/pictures/preview-13.jpg"},{id:815112,nr:14,picture:"https://images.pexels.com/videos/3571264/pictures/preview-14.jpg"}]},{id:6394054,width:4096,height:2048,duration:12,full_res:null,tags:[],url:"https://www.pexels.com/video/waterfall-in-the-forest-6394054/",image:"https://images.pexels.com/videos/6394054/adventure-beauty-forrest-hike-6394054.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:417939,name:"Peter Fowler",url:"https://www.pexels.com/@peter-fowler-417939"},video_files:[{id:10039360,quality:"uhd",file_type:"video/mp4",width:2732,height:1366,fps:23.976,link:"https://videos.pexels.com/video-files/6394054/6394054-uhd_2732_1366_24fps.mp4"},{id:10039416,quality:"sd",file_type:"video/mp4",width:640,height:320,fps:23.976,link:"https://videos.pexels.com/video-files/6394054/6394054-sd_640_320_24fps.mp4"},{id:10039481,quality:"sd",file_type:"video/mp4",width:426,height:214,fps:23.976,link:"https://videos.pexels.com/video-files/6394054/6394054-sd_426_214_24fps.mp4"},{id:10039599,quality:"uhd",file_type:"video/mp4",width:4096,height:2048,fps:23.976,link:"https://videos.pexels.com/video-files/6394054/6394054-uhd_4096_2048_24fps.mp4"},{id:10039683,quality:"hd",file_type:"video/mp4",width:2048,height:1024,fps:23.976,link:"https://videos.pexels.com/video-files/6394054/6394054-hd_2048_1024_24fps.mp4"},{id:10039774,quality:"hd",file_type:"video/mp4",width:1366,height:684,fps:23.976,link:"https://videos.pexels.com/video-files/6394054/6394054-hd_1366_684_24fps.mp4"},{id:10039880,quality:"sd",file_type:"video/mp4",width:960,height:480,fps:23.976,link:"https://videos.pexels.com/video-files/6394054/6394054-sd_960_480_24fps.mp4"}],video_pictures:[{id:4391143,nr:0,picture:"https://images.pexels.com/videos/6394054/pictures/preview-0.jpg"},{id:4391144,nr:1,picture:"https://images.pexels.com/videos/6394054/pictures/preview-1.jpg"},{id:4391145,nr:2,picture:"https://images.pexels.com/videos/6394054/pictures/preview-2.jpg"},{id:4391146,nr:3,picture:"https://images.pexels.com/videos/6394054/pictures/preview-3.jpg"},{id:4391147,nr:4,picture:"https://images.pexels.com/videos/6394054/pictures/preview-4.jpg"},{id:4391148,nr:5,picture:"https://images.pexels.com/videos/6394054/pictures/preview-5.jpg"},{id:4391149,nr:6,picture:"https://images.pexels.com/videos/6394054/pictures/preview-6.jpg"},{id:4391150,nr:7,picture:"https://images.pexels.com/videos/6394054/pictures/preview-7.jpg"},{id:4391151,nr:8,picture:"https://images.pexels.com/videos/6394054/pictures/preview-8.jpg"},{id:4391152,nr:9,picture:"https://images.pexels.com/videos/6394054/pictures/preview-9.jpg"},{id:4391153,nr:10,picture:"https://images.pexels.com/videos/6394054/pictures/preview-10.jpg"},{id:4391154,nr:11,picture:"https://images.pexels.com/videos/6394054/pictures/preview-11.jpg"},{id:4391155,nr:12,picture:"https://images.pexels.com/videos/6394054/pictures/preview-12.jpg"},{id:4391156,nr:13,picture:"https://images.pexels.com/videos/6394054/pictures/preview-13.jpg"},{id:4391157,nr:14,picture:"https://images.pexels.com/videos/6394054/pictures/preview-14.jpg"}]},{id:6981411,width:1920,height:1080,duration:14,full_res:null,tags:[],url:"https://www.pexels.com/video/a-magnificent-view-of-the-waterfalls-6981411/",image:"https://images.pexels.com/videos/6981411/pexels-photo-6981411.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:11437196,name:"Mikhail Nilov",url:"https://www.pexels.com/@mikhail-nilov"},video_files:[{id:10264058,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:25,link:"https://videos.pexels.com/video-files/6981411/6981411-sd_426_240_25fps.mp4"},{id:10264103,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:25,link:"https://videos.pexels.com/video-files/6981411/6981411-hd_1920_1080_25fps.mp4"},{id:10264198,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:25,link:"https://videos.pexels.com/video-files/6981411/6981411-sd_640_360_25fps.mp4"},{id:10264252,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:25,link:"https://videos.pexels.com/video-files/6981411/6981411-sd_960_540_25fps.mp4"},{id:10264301,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:25,link:"https://videos.pexels.com/video-files/6981411/6981411-hd_1280_720_25fps.mp4"}],video_pictures:[{id:5526606,nr:0,picture:"https://images.pexels.com/videos/6981411/pictures/preview-0.jpg"},{id:5526617,nr:1,picture:"https://images.pexels.com/videos/6981411/pictures/preview-1.jpg"},{id:5526631,nr:2,picture:"https://images.pexels.com/videos/6981411/pictures/preview-2.jpg"},{id:5526642,nr:3,picture:"https://images.pexels.com/videos/6981411/pictures/preview-3.jpg"},{id:5526653,nr:4,picture:"https://images.pexels.com/videos/6981411/pictures/preview-4.jpg"},{id:5526673,nr:5,picture:"https://images.pexels.com/videos/6981411/pictures/preview-5.jpg"},{id:5526683,nr:6,picture:"https://images.pexels.com/videos/6981411/pictures/preview-6.jpg"},{id:5526691,nr:7,picture:"https://images.pexels.com/videos/6981411/pictures/preview-7.jpg"},{id:5526699,nr:8,picture:"https://images.pexels.com/videos/6981411/pictures/preview-8.jpg"},{id:5526703,nr:9,picture:"https://images.pexels.com/videos/6981411/pictures/preview-9.jpg"},{id:5526710,nr:10,picture:"https://images.pexels.com/videos/6981411/pictures/preview-10.jpg"},{id:5526717,nr:11,picture:"https://images.pexels.com/videos/6981411/pictures/preview-11.jpg"},{id:5526721,nr:12,picture:"https://images.pexels.com/videos/6981411/pictures/preview-12.jpg"},{id:5526729,nr:13,picture:"https://images.pexels.com/videos/6981411/pictures/preview-13.jpg"},{id:5526737,nr:14,picture:"https://images.pexels.com/videos/6981411/pictures/preview-14.jpg"}]},{id:3173312,width:3840,height:2160,duration:6,full_res:null,tags:[],url:"https://www.pexels.com/video/the-strong-force-of-niagara-falls-3173312/",image:"https://images.pexels.com/videos/3173312/free-video-3173312.jpg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:1659830,name:"Aric Shelby",url:"https://www.pexels.com/@aric-shelby-1659830"},video_files:[{id:9308593,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:29.97,link:"https://videos.pexels.com/video-files/3173312/3173312-hd_1920_1080_30fps.mp4"},{id:9308692,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:29.97,link:"https://videos.pexels.com/video-files/3173312/3173312-hd_1280_720_30fps.mp4"},{id:9308741,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:29.97,link:"https://videos.pexels.com/video-files/3173312/3173312-sd_426_240_30fps.mp4"},{id:9308786,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:29.97,link:"https://videos.pexels.com/video-files/3173312/3173312-sd_640_360_30fps.mp4"},{id:9308822,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:29.97,link:"https://videos.pexels.com/video-files/3173312/3173312-uhd_3840_2160_30fps.mp4"},{id:9308862,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:29.97,link:"https://videos.pexels.com/video-files/3173312/3173312-sd_960_540_30fps.mp4"},{id:9308886,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:29.97,link:"https://videos.pexels.com/video-files/3173312/3173312-uhd_2560_1440_30fps.mp4"}],video_pictures:[{id:564924,nr:0,picture:"https://images.pexels.com/videos/3173312/pictures/preview-0.jpg"},{id:564931,nr:1,picture:"https://images.pexels.com/videos/3173312/pictures/preview-1.jpg"},{id:564936,nr:2,picture:"https://images.pexels.com/videos/3173312/pictures/preview-2.jpg"},{id:564943,nr:3,picture:"https://images.pexels.com/videos/3173312/pictures/preview-3.jpg"},{id:564950,nr:4,picture:"https://images.pexels.com/videos/3173312/pictures/preview-4.jpg"},{id:564956,nr:5,picture:"https://images.pexels.com/videos/3173312/pictures/preview-5.jpg"},{id:564961,nr:6,picture:"https://images.pexels.com/videos/3173312/pictures/preview-6.jpg"},{id:564967,nr:7,picture:"https://images.pexels.com/videos/3173312/pictures/preview-7.jpg"},{id:564973,nr:8,picture:"https://images.pexels.com/videos/3173312/pictures/preview-8.jpg"},{id:564979,nr:9,picture:"https://images.pexels.com/videos/3173312/pictures/preview-9.jpg"},{id:564984,nr:10,picture:"https://images.pexels.com/videos/3173312/pictures/preview-10.jpg"},{id:564988,nr:11,picture:"https://images.pexels.com/videos/3173312/pictures/preview-11.jpg"},{id:564993,nr:12,picture:"https://images.pexels.com/videos/3173312/pictures/preview-12.jpg"},{id:565e3,nr:13,picture:"https://images.pexels.com/videos/3173312/pictures/preview-13.jpg"},{id:565006,nr:14,picture:"https://images.pexels.com/videos/3173312/pictures/preview-14.jpg"}]},{id:4763824,width:3840,height:2160,duration:14,full_res:null,tags:[],url:"https://www.pexels.com/video/drone-flying-over-the-mountain-peak-4763824/",image:"https://images.pexels.com/videos/4763824/4k-4k50fps-adventure-backpack-4763824.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:649765,name:"Yaroslav Shuraev",url:"https://www.pexels.com/@yaroslav-shuraev"},video_files:[{id:9394174,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:24,link:"https://videos.pexels.com/video-files/4763824/4763824-hd_1280_720_24fps.mp4"},{id:9394207,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:24,link:"https://videos.pexels.com/video-files/4763824/4763824-sd_960_540_24fps.mp4"},{id:9394288,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:24,link:"https://videos.pexels.com/video-files/4763824/4763824-hd_1920_1080_24fps.mp4"},{id:9394375,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:24,link:"https://videos.pexels.com/video-files/4763824/4763824-sd_640_360_24fps.mp4"},{id:9394476,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:24,link:"https://videos.pexels.com/video-files/4763824/4763824-uhd_2560_1440_24fps.mp4"},{id:9394622,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:24,link:"https://videos.pexels.com/video-files/4763824/4763824-uhd_3840_2160_24fps.mp4"},{id:9394730,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:24,link:"https://videos.pexels.com/video-files/4763824/4763824-sd_426_240_24fps.mp4"}],video_pictures:[{id:1911019,nr:0,picture:"https://images.pexels.com/videos/4763824/pictures/preview-0.jpg"},{id:1911020,nr:1,picture:"https://images.pexels.com/videos/4763824/pictures/preview-1.jpg"},{id:1911021,nr:2,picture:"https://images.pexels.com/videos/4763824/pictures/preview-2.jpg"},{id:1911022,nr:3,picture:"https://images.pexels.com/videos/4763824/pictures/preview-3.jpg"},{id:1911023,nr:4,picture:"https://images.pexels.com/videos/4763824/pictures/preview-4.jpg"},{id:1911024,nr:5,picture:"https://images.pexels.com/videos/4763824/pictures/preview-5.jpg"},{id:1911025,nr:6,picture:"https://images.pexels.com/videos/4763824/pictures/preview-6.jpg"},{id:1911026,nr:7,picture:"https://images.pexels.com/videos/4763824/pictures/preview-7.jpg"},{id:1911027,nr:8,picture:"https://images.pexels.com/videos/4763824/pictures/preview-8.jpg"},{id:1911028,nr:9,picture:"https://images.pexels.com/videos/4763824/pictures/preview-9.jpg"},{id:1911029,nr:10,picture:"https://images.pexels.com/videos/4763824/pictures/preview-10.jpg"},{id:1911030,nr:11,picture:"https://images.pexels.com/videos/4763824/pictures/preview-11.jpg"},{id:1911031,nr:12,picture:"https://images.pexels.com/videos/4763824/pictures/preview-12.jpg"},{id:1911032,nr:13,picture:"https://images.pexels.com/videos/4763824/pictures/preview-13.jpg"},{id:1911033,nr:14,picture:"https://images.pexels.com/videos/4763824/pictures/preview-14.jpg"}]},{id:8820216,width:3840,height:2160,duration:20,full_res:null,tags:[],url:"https://www.pexels.com/video/aerial-shot-of-a-landscape-8820216/",image:"https://images.pexels.com/videos/8820216/aerial-footage-aerial-video-aerial-view-at-the-beach-8820216.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:1522664,name:"Taryn Elliott",url:"https://www.pexels.com/@taryn-elliott"},video_files:[{id:10962308,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:25,link:"https://videos.pexels.com/video-files/8820216/8820216-sd_960_540_25fps.mp4"},{id:10962345,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:25,link:"https://videos.pexels.com/video-files/8820216/8820216-hd_1920_1080_25fps.mp4"},{id:10962399,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:25,link:"https://videos.pexels.com/video-files/8820216/8820216-uhd_2560_1440_25fps.mp4"},{id:10962546,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:25,link:"https://videos.pexels.com/video-files/8820216/8820216-uhd_3840_2160_25fps.mp4"},{id:10962595,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:25,link:"https://videos.pexels.com/video-files/8820216/8820216-hd_1280_720_25fps.mp4"},{id:10962637,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:25,link:"https://videos.pexels.com/video-files/8820216/8820216-sd_426_240_25fps.mp4"},{id:10962702,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:25,link:"https://videos.pexels.com/video-files/8820216/8820216-sd_640_360_25fps.mp4"}],video_pictures:[{id:8879206,nr:0,picture:"https://images.pexels.com/videos/8820216/pictures/preview-0.jpeg"},{id:8879209,nr:1,picture:"https://images.pexels.com/videos/8820216/pictures/preview-1.jpeg"},{id:8879213,nr:2,picture:"https://images.pexels.com/videos/8820216/pictures/preview-2.jpeg"},{id:8879217,nr:3,picture:"https://images.pexels.com/videos/8820216/pictures/preview-3.jpeg"},{id:8879221,nr:4,picture:"https://images.pexels.com/videos/8820216/pictures/preview-4.jpeg"},{id:8879228,nr:5,picture:"https://images.pexels.com/videos/8820216/pictures/preview-5.jpeg"},{id:8879233,nr:6,picture:"https://images.pexels.com/videos/8820216/pictures/preview-6.jpeg"},{id:8879239,nr:7,picture:"https://images.pexels.com/videos/8820216/pictures/preview-7.jpeg"},{id:8879246,nr:8,picture:"https://images.pexels.com/videos/8820216/pictures/preview-8.jpeg"},{id:8879251,nr:9,picture:"https://images.pexels.com/videos/8820216/pictures/preview-9.jpeg"},{id:8879256,nr:10,picture:"https://images.pexels.com/videos/8820216/pictures/preview-10.jpeg"},{id:8879259,nr:11,picture:"https://images.pexels.com/videos/8820216/pictures/preview-11.jpeg"},{id:8879262,nr:12,picture:"https://images.pexels.com/videos/8820216/pictures/preview-12.jpeg"},{id:8879265,nr:13,picture:"https://images.pexels.com/videos/8820216/pictures/preview-13.jpeg"},{id:8879269,nr:14,picture:"https://images.pexels.com/videos/8820216/pictures/preview-14.jpeg"}]},{id:5896379,width:2160,height:3840,duration:30,full_res:null,tags:[],url:"https://www.pexels.com/video/a-rocky-river-in-the-forest-5896379/",image:"https://images.pexels.com/videos/5896379/aerial-footage-aerial-fotoage-aerial-video-aerial-view-5896379.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=1200&w=630",avg_color:null,user:{id:574687,name:"Ruvim Miksanskiy",url:"https://www.pexels.com/@digitech"},video_files:[{id:9851339,quality:"sd",file_type:"video/mp4",width:540,height:960,fps:23.976,link:"https://videos.pexels.com/video-files/5896379/5896379-sd_540_960_24fps.mp4"},{id:9851435,quality:"sd",file_type:"video/mp4",width:360,height:640,fps:23.976,link:"https://videos.pexels.com/video-files/5896379/5896379-sd_360_640_24fps.mp4"},{id:9851542,quality:"sd",file_type:"video/mp4",width:240,height:426,fps:23.976,link:"https://videos.pexels.com/video-files/5896379/5896379-sd_240_426_24fps.mp4"},{id:9851604,quality:"hd",file_type:"video/mp4",width:720,height:1280,fps:23.976,link:"https://videos.pexels.com/video-files/5896379/5896379-hd_720_1280_24fps.mp4"},{id:9851676,quality:"uhd",file_type:"video/mp4",width:2160,height:3840,fps:23.976,link:"https://videos.pexels.com/video-files/5896379/5896379-uhd_2160_3840_24fps.mp4"},{id:9851745,quality:"hd",file_type:"video/mp4",width:1080,height:1920,fps:23.976,link:"https://videos.pexels.com/video-files/5896379/5896379-hd_1080_1920_24fps.mp4"},{id:9851811,quality:"uhd",file_type:"video/mp4",width:1440,height:2560,fps:23.976,link:"https://videos.pexels.com/video-files/5896379/5896379-uhd_1440_2560_24fps.mp4"}],video_pictures:[{id:3541669,nr:0,picture:"https://images.pexels.com/videos/5896379/pictures/preview-0.jpeg"},{id:3541672,nr:1,picture:"https://images.pexels.com/videos/5896379/pictures/preview-1.jpeg"},{id:3541675,nr:2,picture:"https://images.pexels.com/videos/5896379/pictures/preview-2.jpeg"},{id:3541679,nr:3,picture:"https://images.pexels.com/videos/5896379/pictures/preview-3.jpeg"},{id:3541683,nr:4,picture:"https://images.pexels.com/videos/5896379/pictures/preview-4.jpeg"},{id:3541686,nr:5,picture:"https://images.pexels.com/videos/5896379/pictures/preview-5.jpeg"},{id:3541689,nr:6,picture:"https://images.pexels.com/videos/5896379/pictures/preview-6.jpeg"},{id:3541694,nr:7,picture:"https://images.pexels.com/videos/5896379/pictures/preview-7.jpeg"},{id:3541696,nr:8,picture:"https://images.pexels.com/videos/5896379/pictures/preview-8.jpeg"},{id:3541698,nr:9,picture:"https://images.pexels.com/videos/5896379/pictures/preview-9.jpeg"},{id:3541701,nr:10,picture:"https://images.pexels.com/videos/5896379/pictures/preview-10.jpeg"},{id:3541705,nr:11,picture:"https://images.pexels.com/videos/5896379/pictures/preview-11.jpeg"},{id:3541709,nr:12,picture:"https://images.pexels.com/videos/5896379/pictures/preview-12.jpeg"},{id:3541713,nr:13,picture:"https://images.pexels.com/videos/5896379/pictures/preview-13.jpeg"},{id:3541717,nr:14,picture:"https://images.pexels.com/videos/5896379/pictures/preview-14.jpeg"}]},{id:1448735,width:4096,height:2160,duration:32,full_res:null,tags:[],url:"https://www.pexels.com/video/video-of-forest-1448735/",image:"https://images.pexels.com/videos/1448735/free-video-1448735.jpg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:574687,name:"Ruvim Miksanskiy",url:"https://www.pexels.com/@digitech"},video_files:[{id:9263650,quality:"hd",file_type:"video/mp4",width:1366,height:720,fps:23.98,link:"https://videos.pexels.com/video-files/1448735/1448735-hd_1366_720_24fps.mp4"},{id:9263711,quality:"hd",file_type:"video/mp4",width:2048,height:1080,fps:23.98,link:"https://videos.pexels.com/video-files/1448735/1448735-hd_2048_1080_24fps.mp4"},{id:9263880,quality:"uhd",file_type:"video/mp4",width:4096,height:2160,fps:23.98,link:"https://videos.pexels.com/video-files/1448735/1448735-uhd_4096_2160_24fps.mp4"},{id:9264080,quality:"uhd",file_type:"video/mp4",width:2732,height:1440,fps:23.98,link:"https://videos.pexels.com/video-files/1448735/1448735-uhd_2732_1440_24fps.mp4"},{id:9264158,quality:"sd",file_type:"video/mp4",width:960,height:506,fps:23.98,link:"https://videos.pexels.com/video-files/1448735/1448735-sd_960_506_24fps.mp4"},{id:9264327,quality:"sd",file_type:"video/mp4",width:640,height:338,fps:23.98,link:"https://videos.pexels.com/video-files/1448735/1448735-sd_640_338_24fps.mp4"}],video_pictures:[{id:133236,nr:0,picture:"https://images.pexels.com/videos/1448735/pictures/preview-0.jpg"},{id:133237,nr:1,picture:"https://images.pexels.com/videos/1448735/pictures/preview-1.jpg"},{id:133238,nr:2,picture:"https://images.pexels.com/videos/1448735/pictures/preview-2.jpg"},{id:133239,nr:3,picture:"https://images.pexels.com/videos/1448735/pictures/preview-3.jpg"},{id:133240,nr:4,picture:"https://images.pexels.com/videos/1448735/pictures/preview-4.jpg"},{id:133241,nr:5,picture:"https://images.pexels.com/videos/1448735/pictures/preview-5.jpg"},{id:133242,nr:6,picture:"https://images.pexels.com/videos/1448735/pictures/preview-6.jpg"},{id:133243,nr:7,picture:"https://images.pexels.com/videos/1448735/pictures/preview-7.jpg"},{id:133244,nr:8,picture:"https://images.pexels.com/videos/1448735/pictures/preview-8.jpg"},{id:133245,nr:9,picture:"https://images.pexels.com/videos/1448735/pictures/preview-9.jpg"},{id:133246,nr:10,picture:"https://images.pexels.com/videos/1448735/pictures/preview-10.jpg"},{id:133247,nr:11,picture:"https://images.pexels.com/videos/1448735/pictures/preview-11.jpg"},{id:133248,nr:12,picture:"https://images.pexels.com/videos/1448735/pictures/preview-12.jpg"},{id:133249,nr:13,picture:"https://images.pexels.com/videos/1448735/pictures/preview-13.jpg"},{id:133250,nr:14,picture:"https://images.pexels.com/videos/1448735/pictures/preview-14.jpg"}]},{id:3214448,width:3840,height:2160,duration:60,full_res:null,tags:[],url:"https://www.pexels.com/video/icecaps-covering-the-mountains-ranges-3214448/",image:"https://images.pexels.com/videos/3214448/free-video-3214448.jpg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:1583460,name:"Pressmaster",url:"https://www.pexels.com/@pressmaster"},video_files:[{id:9293564,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:25,link:"https://videos.pexels.com/video-files/3214448/3214448-sd_960_540_25fps.mp4"},{id:9293589,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:25,link:"https://videos.pexels.com/video-files/3214448/3214448-sd_640_360_25fps.mp4"},{id:9293620,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:25,link:"https://videos.pexels.com/video-files/3214448/3214448-sd_426_240_25fps.mp4"},{id:9293658,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:25,link:"https://videos.pexels.com/video-files/3214448/3214448-hd_1920_1080_25fps.mp4"},{id:9293703,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:25,link:"https://videos.pexels.com/video-files/3214448/3214448-uhd_3840_2160_25fps.mp4"},{id:9293734,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:25,link:"https://videos.pexels.com/video-files/3214448/3214448-hd_1280_720_25fps.mp4"},{id:9293774,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:25,link:"https://videos.pexels.com/video-files/3214448/3214448-uhd_2560_1440_25fps.mp4"}],video_pictures:[{id:593937,nr:0,picture:"https://images.pexels.com/videos/3214448/pictures/preview-0.jpg"},{id:593938,nr:1,picture:"https://images.pexels.com/videos/3214448/pictures/preview-1.jpg"},{id:593939,nr:2,picture:"https://images.pexels.com/videos/3214448/pictures/preview-2.jpg"},{id:593940,nr:3,picture:"https://images.pexels.com/videos/3214448/pictures/preview-3.jpg"},{id:593941,nr:4,picture:"https://images.pexels.com/videos/3214448/pictures/preview-4.jpg"},{id:593942,nr:5,picture:"https://images.pexels.com/videos/3214448/pictures/preview-5.jpg"},{id:593944,nr:6,picture:"https://images.pexels.com/videos/3214448/pictures/preview-6.jpg"},{id:593947,nr:7,picture:"https://images.pexels.com/videos/3214448/pictures/preview-7.jpg"},{id:593948,nr:8,picture:"https://images.pexels.com/videos/3214448/pictures/preview-8.jpg"},{id:593951,nr:9,picture:"https://images.pexels.com/videos/3214448/pictures/preview-9.jpg"},{id:593952,nr:10,picture:"https://images.pexels.com/videos/3214448/pictures/preview-10.jpg"},{id:593954,nr:11,picture:"https://images.pexels.com/videos/3214448/pictures/preview-11.jpg"},{id:593956,nr:12,picture:"https://images.pexels.com/videos/3214448/pictures/preview-12.jpg"},{id:593958,nr:13,picture:"https://images.pexels.com/videos/3214448/pictures/preview-13.jpg"},{id:593960,nr:14,picture:"https://images.pexels.com/videos/3214448/pictures/preview-14.jpg"}]},{id:2098989,width:3840,height:2160,duration:36,full_res:null,tags:[],url:"https://www.pexels.com/video/beauty-of-waterfalls-2098989/",image:"https://images.pexels.com/videos/2098989/free-video-2098989.jpg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:631997,name:"Engin Akyurt",url:"https://www.pexels.com/@enginakyurt"},video_files:[{id:9266944,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:29.97,link:"https://videos.pexels.com/video-files/2098989/2098989-hd_1280_720_30fps.mp4"},{id:9266961,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:29.97,link:"https://videos.pexels.com/video-files/2098989/2098989-uhd_3840_2160_30fps.mp4"},{id:9266988,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:29.97,link:"https://videos.pexels.com/video-files/2098989/2098989-uhd_2560_1440_30fps.mp4"},{id:9267011,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:29.97,link:"https://videos.pexels.com/video-files/2098989/2098989-sd_640_360_30fps.mp4"},{id:9267040,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:29.97,link:"https://videos.pexels.com/video-files/2098989/2098989-hd_1920_1080_30fps.mp4"},{id:9267060,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:29.97,link:"https://videos.pexels.com/video-files/2098989/2098989-sd_960_540_30fps.mp4"}],video_pictures:[{id:222873,nr:0,picture:"https://images.pexels.com/videos/2098989/pictures/preview-0.jpg"},{id:222874,nr:1,picture:"https://images.pexels.com/videos/2098989/pictures/preview-1.jpg"},{id:222875,nr:2,picture:"https://images.pexels.com/videos/2098989/pictures/preview-2.jpg"},{id:222876,nr:3,picture:"https://images.pexels.com/videos/2098989/pictures/preview-3.jpg"},{id:222877,nr:4,picture:"https://images.pexels.com/videos/2098989/pictures/preview-4.jpg"},{id:222878,nr:5,picture:"https://images.pexels.com/videos/2098989/pictures/preview-5.jpg"},{id:222879,nr:6,picture:"https://images.pexels.com/videos/2098989/pictures/preview-6.jpg"},{id:222880,nr:7,picture:"https://images.pexels.com/videos/2098989/pictures/preview-7.jpg"},{id:222881,nr:8,picture:"https://images.pexels.com/videos/2098989/pictures/preview-8.jpg"},{id:222882,nr:9,picture:"https://images.pexels.com/videos/2098989/pictures/preview-9.jpg"},{id:222883,nr:10,picture:"https://images.pexels.com/videos/2098989/pictures/preview-10.jpg"},{id:222884,nr:11,picture:"https://images.pexels.com/videos/2098989/pictures/preview-11.jpg"},{id:222885,nr:12,picture:"https://images.pexels.com/videos/2098989/pictures/preview-12.jpg"},{id:222886,nr:13,picture:"https://images.pexels.com/videos/2098989/pictures/preview-13.jpg"},{id:222887,nr:14,picture:"https://images.pexels.com/videos/2098989/pictures/preview-14.jpg"}]},{id:4812203,width:1080,height:1920,duration:16,full_res:null,tags:[],url:"https://www.pexels.com/video/wheat-plants-in-field-4812203/",image:"https://images.pexels.com/videos/4812203/air-child-dad-dress-4812203.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=1200&w=630",avg_color:null,user:{id:2297095,name:"Pavel Danilyuk",url:"https://www.pexels.com/@pavel-danilyuk"},video_files:[{id:9403438,quality:"hd",file_type:"video/mp4",width:1080,height:1920,fps:29.97,link:"https://videos.pexels.com/video-files/4812203/4812203-hd_1080_1920_30fps.mp4"},{id:9403512,quality:"hd",file_type:"video/mp4",width:720,height:1280,fps:29.97,link:"https://videos.pexels.com/video-files/4812203/4812203-hd_720_1280_30fps.mp4"},{id:9403537,quality:"sd",file_type:"video/mp4",width:540,height:960,fps:29.97,link:"https://videos.pexels.com/video-files/4812203/4812203-sd_540_960_30fps.mp4"},{id:9403689,quality:"sd",file_type:"video/mp4",width:360,height:640,fps:29.97,link:"https://videos.pexels.com/video-files/4812203/4812203-sd_360_640_30fps.mp4"},{id:9403736,quality:"sd",file_type:"video/mp4",width:240,height:426,fps:29.97,link:"https://videos.pexels.com/video-files/4812203/4812203-sd_240_426_30fps.mp4"}],video_pictures:[{id:1958434,nr:0,picture:"https://images.pexels.com/videos/4812203/pictures/preview-0.jpeg"},{id:1958435,nr:1,picture:"https://images.pexels.com/videos/4812203/pictures/preview-1.jpeg"},{id:1958436,nr:2,picture:"https://images.pexels.com/videos/4812203/pictures/preview-2.jpeg"},{id:1958437,nr:3,picture:"https://images.pexels.com/videos/4812203/pictures/preview-3.jpeg"},{id:1958438,nr:4,picture:"https://images.pexels.com/videos/4812203/pictures/preview-4.jpeg"},{id:1958439,nr:5,picture:"https://images.pexels.com/videos/4812203/pictures/preview-5.jpeg"},{id:1958440,nr:6,picture:"https://images.pexels.com/videos/4812203/pictures/preview-6.jpeg"},{id:1958441,nr:7,picture:"https://images.pexels.com/videos/4812203/pictures/preview-7.jpeg"},{id:1958442,nr:8,picture:"https://images.pexels.com/videos/4812203/pictures/preview-8.jpeg"},{id:1958443,nr:9,picture:"https://images.pexels.com/videos/4812203/pictures/preview-9.jpeg"},{id:1958444,nr:10,picture:"https://images.pexels.com/videos/4812203/pictures/preview-10.jpeg"},{id:1958445,nr:11,picture:"https://images.pexels.com/videos/4812203/pictures/preview-11.jpeg"},{id:1958446,nr:12,picture:"https://images.pexels.com/videos/4812203/pictures/preview-12.jpeg"},{id:1958447,nr:13,picture:"https://images.pexels.com/videos/4812203/pictures/preview-13.jpeg"},{id:1958448,nr:14,picture:"https://images.pexels.com/videos/4812203/pictures/preview-14.jpeg"}]},{id:4205697,width:3840,height:2160,duration:46,full_res:null,tags:[],url:"https://www.pexels.com/video/a-drone-shot-of-a-mountain-island-4205697/",image:"https://images.pexels.com/videos/4205697/bay-bay-area-beach-island-beach-shore-4205697.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:649765,name:"Yaroslav Shuraev",url:"https://www.pexels.com/@yaroslav-shuraev"},video_files:[{id:9499102,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:29.97,link:"https://videos.pexels.com/video-files/4205697/4205697-sd_960_540_30fps.mp4"},{id:9499179,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:29.97,link:"https://videos.pexels.com/video-files/4205697/4205697-sd_640_360_30fps.mp4"},{id:9499233,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:29.97,link:"https://videos.pexels.com/video-files/4205697/4205697-uhd_3840_2160_30fps.mp4"},{id:9499258,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:29.97,link:"https://videos.pexels.com/video-files/4205697/4205697-hd_1920_1080_30fps.mp4"},{id:9499320,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:29.97,link:"https://videos.pexels.com/video-files/4205697/4205697-hd_1280_720_30fps.mp4"},{id:9499368,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:29.97,link:"https://videos.pexels.com/video-files/4205697/4205697-uhd_2560_1440_30fps.mp4"},{id:9499432,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:29.97,link:"https://videos.pexels.com/video-files/4205697/4205697-sd_426_240_30fps.mp4"}],video_pictures:[{id:1265068,nr:0,picture:"https://images.pexels.com/videos/4205697/pictures/preview-0.jpg"},{id:1265076,nr:1,picture:"https://images.pexels.com/videos/4205697/pictures/preview-1.jpg"},{id:1265081,nr:2,picture:"https://images.pexels.com/videos/4205697/pictures/preview-2.jpg"},{id:1265082,nr:3,picture:"https://images.pexels.com/videos/4205697/pictures/preview-3.jpg"},{id:1265084,nr:4,picture:"https://images.pexels.com/videos/4205697/pictures/preview-4.jpg"},{id:1265086,nr:5,picture:"https://images.pexels.com/videos/4205697/pictures/preview-5.jpg"},{id:1265088,nr:6,picture:"https://images.pexels.com/videos/4205697/pictures/preview-6.jpg"},{id:1265090,nr:7,picture:"https://images.pexels.com/videos/4205697/pictures/preview-7.jpg"},{id:1265091,nr:8,picture:"https://images.pexels.com/videos/4205697/pictures/preview-8.jpg"},{id:1265094,nr:9,picture:"https://images.pexels.com/videos/4205697/pictures/preview-9.jpg"},{id:1265096,nr:10,picture:"https://images.pexels.com/videos/4205697/pictures/preview-10.jpg"},{id:1265098,nr:11,picture:"https://images.pexels.com/videos/4205697/pictures/preview-11.jpg"},{id:1265100,nr:12,picture:"https://images.pexels.com/videos/4205697/pictures/preview-12.jpg"},{id:1265103,nr:13,picture:"https://images.pexels.com/videos/4205697/pictures/preview-13.jpg"},{id:1265105,nr:14,picture:"https://images.pexels.com/videos/4205697/pictures/preview-14.jpg"}]},{id:5147455,width:1080,height:1920,duration:14,full_res:null,tags:[],url:"https://www.pexels.com/video/view-of-sunset-from-the-beach-5147455/",image:"https://images.pexels.com/videos/5147455/beach-hua-hin-sunrise-thaliand-5147455.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=1200&w=630",avg_color:null,user:{id:3006127,name:"Christopher Schultz",url:"https://www.pexels.com/@christopher-schultz-3006127"},video_files:[{id:9631351,quality:"hd",file_type:"video/mp4",width:720,height:1280,fps:29.97,link:"https://videos.pexels.com/video-files/5147455/5147455-hd_720_1280_30fps.mp4"},{id:9631455,quality:"sd",file_type:"video/mp4",width:540,height:960,fps:29.97,link:"https://videos.pexels.com/video-files/5147455/5147455-sd_540_960_30fps.mp4"},{id:9631518,quality:"hd",file_type:"video/mp4",width:1080,height:1920,fps:29.97,link:"https://videos.pexels.com/video-files/5147455/5147455-hd_1080_1920_30fps.mp4"},{id:9631603,quality:"sd",file_type:"video/mp4",width:360,height:640,fps:29.97,link:"https://videos.pexels.com/video-files/5147455/5147455-sd_360_640_30fps.mp4"},{id:9631674,quality:"sd",file_type:"video/mp4",width:240,height:426,fps:29.97,link:"https://videos.pexels.com/video-files/5147455/5147455-sd_240_426_30fps.mp4"}],video_pictures:[{id:2424485,nr:0,picture:"https://images.pexels.com/videos/5147455/pictures/preview-0.jpeg"},{id:2424486,nr:1,picture:"https://images.pexels.com/videos/5147455/pictures/preview-1.jpeg"},{id:2424487,nr:2,picture:"https://images.pexels.com/videos/5147455/pictures/preview-2.jpeg"},{id:2424488,nr:3,picture:"https://images.pexels.com/videos/5147455/pictures/preview-3.jpeg"},{id:2424489,nr:4,picture:"https://images.pexels.com/videos/5147455/pictures/preview-4.jpeg"},{id:2424490,nr:5,picture:"https://images.pexels.com/videos/5147455/pictures/preview-5.jpeg"},{id:2424491,nr:6,picture:"https://images.pexels.com/videos/5147455/pictures/preview-6.jpeg"},{id:2424492,nr:7,picture:"https://images.pexels.com/videos/5147455/pictures/preview-7.jpeg"},{id:2424493,nr:8,picture:"https://images.pexels.com/videos/5147455/pictures/preview-8.jpeg"},{id:2424494,nr:9,picture:"https://images.pexels.com/videos/5147455/pictures/preview-9.jpeg"},{id:2424495,nr:10,picture:"https://images.pexels.com/videos/5147455/pictures/preview-10.jpeg"},{id:2424496,nr:11,picture:"https://images.pexels.com/videos/5147455/pictures/preview-11.jpeg"},{id:2424497,nr:12,picture:"https://images.pexels.com/videos/5147455/pictures/preview-12.jpeg"},{id:2424499,nr:13,picture:"https://images.pexels.com/videos/5147455/pictures/preview-13.jpeg"},{id:2424500,nr:14,picture:"https://images.pexels.com/videos/5147455/pictures/preview-14.jpeg"}]},{id:8856785,width:2160,height:3840,duration:6,full_res:null,tags:[],url:"https://www.pexels.com/video/video-of-a-clownfish-and-sea-anemone-8856785/",image:"https://images.pexels.com/videos/8856785/pexels-photo-8856785.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=1200&w=630",avg_color:null,user:{id:2272619,name:"Rachel Claire",url:"https://www.pexels.com/@rachel-claire"},video_files:[{id:10991437,quality:"hd",file_type:"video/mp4",width:720,height:1280,fps:25,link:"https://videos.pexels.com/video-files/8856785/8856785-hd_720_1280_25fps.mp4"},{id:10991462,quality:"uhd",file_type:"video/mp4",width:2160,height:3840,fps:25,link:"https://videos.pexels.com/video-files/8856785/8856785-uhd_2160_3840_25fps.mp4"},{id:10991525,quality:"uhd",file_type:"video/mp4",width:1440,height:2560,fps:25,link:"https://videos.pexels.com/video-files/8856785/8856785-uhd_1440_2560_25fps.mp4"},{id:10991595,quality:"sd",file_type:"video/mp4",width:360,height:640,fps:25,link:"https://videos.pexels.com/video-files/8856785/8856785-sd_360_640_25fps.mp4"},{id:10991699,quality:"sd",file_type:"video/mp4",width:540,height:960,fps:25,link:"https://videos.pexels.com/video-files/8856785/8856785-sd_540_960_25fps.mp4"},{id:10991768,quality:"hd",file_type:"video/mp4",width:1080,height:1920,fps:25,link:"https://videos.pexels.com/video-files/8856785/8856785-hd_1080_1920_25fps.mp4"}],video_pictures:[{id:8939765,nr:0,picture:"https://images.pexels.com/videos/8856785/pictures/preview-0.jpeg"},{id:8939772,nr:1,picture:"https://images.pexels.com/videos/8856785/pictures/preview-1.jpeg"},{id:8939777,nr:2,picture:"https://images.pexels.com/videos/8856785/pictures/preview-2.jpeg"},{id:8939784,nr:3,picture:"https://images.pexels.com/videos/8856785/pictures/preview-3.jpeg"},{id:8939792,nr:4,picture:"https://images.pexels.com/videos/8856785/pictures/preview-4.jpeg"},{id:8939800,nr:5,picture:"https://images.pexels.com/videos/8856785/pictures/preview-5.jpeg"},{id:8939804,nr:6,picture:"https://images.pexels.com/videos/8856785/pictures/preview-6.jpeg"},{id:8939808,nr:7,picture:"https://images.pexels.com/videos/8856785/pictures/preview-7.jpeg"},{id:8939812,nr:8,picture:"https://images.pexels.com/videos/8856785/pictures/preview-8.jpeg"},{id:8939816,nr:9,picture:"https://images.pexels.com/videos/8856785/pictures/preview-9.jpeg"},{id:8939819,nr:10,picture:"https://images.pexels.com/videos/8856785/pictures/preview-10.jpeg"},{id:8939822,nr:11,picture:"https://images.pexels.com/videos/8856785/pictures/preview-11.jpeg"},{id:8939826,nr:12,picture:"https://images.pexels.com/videos/8856785/pictures/preview-12.jpeg"},{id:8939828,nr:13,picture:"https://images.pexels.com/videos/8856785/pictures/preview-13.jpeg"},{id:8939831,nr:14,picture:"https://images.pexels.com/videos/8856785/pictures/preview-14.jpeg"}]},{id:5946371,width:3840,height:2160,duration:20,full_res:null,tags:[],url:"https://www.pexels.com/video/the-niagara-falls-in-a-close-up-video-5946371/",image:"https://images.pexels.com/videos/5946371/closeup-niagara-falls-niagara-falls-5946371.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:3111579,name:"Sarowar Hussain",url:"https://www.pexels.com/@sarowar-hussain-3111579"},video_files:[{id:9881764,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:29.97,link:"https://videos.pexels.com/video-files/5946371/5946371-sd_960_540_30fps.mp4"},{id:9881779,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:29.97,link:"https://videos.pexels.com/video-files/5946371/5946371-sd_640_360_30fps.mp4"},{id:9881805,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:29.97,link:"https://videos.pexels.com/video-files/5946371/5946371-hd_1920_1080_30fps.mp4"},{id:9881828,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:29.97,link:"https://videos.pexels.com/video-files/5946371/5946371-uhd_3840_2160_30fps.mp4"},{id:9881859,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:29.97,link:"https://videos.pexels.com/video-files/5946371/5946371-uhd_2560_1440_30fps.mp4"},{id:9881887,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:29.97,link:"https://videos.pexels.com/video-files/5946371/5946371-sd_426_240_30fps.mp4"},{id:9881908,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:29.97,link:"https://videos.pexels.com/video-files/5946371/5946371-hd_1280_720_30fps.mp4"}],video_pictures:[{id:3647984,nr:0,picture:"https://images.pexels.com/videos/5946371/pictures/preview-0.jpg"},{id:3647986,nr:1,picture:"https://images.pexels.com/videos/5946371/pictures/preview-1.jpg"},{id:3647987,nr:2,picture:"https://images.pexels.com/videos/5946371/pictures/preview-2.jpg"},{id:3647989,nr:3,picture:"https://images.pexels.com/videos/5946371/pictures/preview-3.jpg"},{id:3647990,nr:4,picture:"https://images.pexels.com/videos/5946371/pictures/preview-4.jpg"},{id:3647992,nr:5,picture:"https://images.pexels.com/videos/5946371/pictures/preview-5.jpg"},{id:3647994,nr:6,picture:"https://images.pexels.com/videos/5946371/pictures/preview-6.jpg"},{id:3647996,nr:7,picture:"https://images.pexels.com/videos/5946371/pictures/preview-7.jpg"},{id:3647997,nr:8,picture:"https://images.pexels.com/videos/5946371/pictures/preview-8.jpg"},{id:3647999,nr:9,picture:"https://images.pexels.com/videos/5946371/pictures/preview-9.jpg"},{id:3648002,nr:10,picture:"https://images.pexels.com/videos/5946371/pictures/preview-10.jpg"},{id:3648003,nr:11,picture:"https://images.pexels.com/videos/5946371/pictures/preview-11.jpg"},{id:3648005,nr:12,picture:"https://images.pexels.com/videos/5946371/pictures/preview-12.jpg"},{id:3648007,nr:13,picture:"https://images.pexels.com/videos/5946371/pictures/preview-13.jpg"},{id:3648009,nr:14,picture:"https://images.pexels.com/videos/5946371/pictures/preview-14.jpg"}]},{id:4919750,width:4096,height:2160,duration:22,full_res:null,tags:[],url:"https://www.pexels.com/video/landscape-nature-field-flowers-4919750/",image:"https://images.pexels.com/videos/4919750/pexels-photo-4919750.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:1437723,name:"cottonbro studio",url:"https://www.pexels.com/@cottonbro"},video_files:[{id:9425407,quality:"sd",file_type:"video/mp4",width:640,height:338,fps:25,link:"https://videos.pexels.com/video-files/4919750/4919750-sd_640_338_25fps.mp4"},{id:9425585,quality:"sd",file_type:"video/mp4",width:960,height:506,fps:25,link:"https://videos.pexels.com/video-files/4919750/4919750-sd_960_506_25fps.mp4"},{id:9425727,quality:"uhd",file_type:"video/mp4",width:4096,height:2160,fps:25,link:"https://videos.pexels.com/video-files/4919750/4919750-uhd_4096_2160_25fps.mp4"},{id:9425820,quality:"sd",file_type:"video/mp4",width:426,height:226,fps:25,link:"https://videos.pexels.com/video-files/4919750/4919750-sd_426_226_25fps.mp4"},{id:9425885,quality:"uhd",file_type:"video/mp4",width:2732,height:1440,fps:25,link:"https://videos.pexels.com/video-files/4919750/4919750-uhd_2732_1440_25fps.mp4"},{id:9426108,quality:"hd",file_type:"video/mp4",width:1366,height:720,fps:25,link:"https://videos.pexels.com/video-files/4919750/4919750-hd_1366_720_25fps.mp4"},{id:9426186,quality:"hd",file_type:"video/mp4",width:2048,height:1080,fps:25,link:"https://videos.pexels.com/video-files/4919750/4919750-hd_2048_1080_25fps.mp4"}],video_pictures:[{id:2117068,nr:0,picture:"https://images.pexels.com/videos/4919750/pictures/preview-0.jpg"},{id:2117085,nr:1,picture:"https://images.pexels.com/videos/4919750/pictures/preview-1.jpg"},{id:2117113,nr:2,picture:"https://images.pexels.com/videos/4919750/pictures/preview-2.jpg"},{id:2117129,nr:3,picture:"https://images.pexels.com/videos/4919750/pictures/preview-3.jpg"},{id:2117150,nr:4,picture:"https://images.pexels.com/videos/4919750/pictures/preview-4.jpg"},{id:2117162,nr:5,picture:"https://images.pexels.com/videos/4919750/pictures/preview-5.jpg"},{id:2117183,nr:6,picture:"https://images.pexels.com/videos/4919750/pictures/preview-6.jpg"},{id:2117191,nr:7,picture:"https://images.pexels.com/videos/4919750/pictures/preview-7.jpg"},{id:2117200,nr:8,picture:"https://images.pexels.com/videos/4919750/pictures/preview-8.jpg"},{id:2117210,nr:9,picture:"https://images.pexels.com/videos/4919750/pictures/preview-9.jpg"},{id:2117217,nr:10,picture:"https://images.pexels.com/videos/4919750/pictures/preview-10.jpg"},{id:2117222,nr:11,picture:"https://images.pexels.com/videos/4919750/pictures/preview-11.jpg"},{id:2117227,nr:12,picture:"https://images.pexels.com/videos/4919750/pictures/preview-12.jpg"},{id:2117237,nr:13,picture:"https://images.pexels.com/videos/4919750/pictures/preview-13.jpg"},{id:2117248,nr:14,picture:"https://images.pexels.com/videos/4919750/pictures/preview-14.jpg"}]},{id:1542008,width:1920,height:1080,duration:58,full_res:null,tags:[],url:"https://www.pexels.com/video/view-of-clouds-on-time-lapse-mode-1542008/",image:"https://images.pexels.com/videos/1542008/free-video-1542008.jpg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:652934,name:"Tuncay Kutlu",url:"https://www.pexels.com/@tuncay-kutlu-652934"},video_files:[{id:9263759,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:29.97,link:"https://videos.pexels.com/video-files/1542008/1542008-sd_960_540_30fps.mp4"},{id:9263790,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:29.97,link:"https://videos.pexels.com/video-files/1542008/1542008-hd_1920_1080_30fps.mp4"},{id:9263841,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:29.97,link:"https://videos.pexels.com/video-files/1542008/1542008-sd_640_360_30fps.mp4"},{id:9263907,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:29.97,link:"https://videos.pexels.com/video-files/1542008/1542008-hd_1280_720_30fps.mp4"}],video_pictures:[{id:143437,nr:0,picture:"https://images.pexels.com/videos/1542008/pictures/preview-0.jpg"},{id:143438,nr:1,picture:"https://images.pexels.com/videos/1542008/pictures/preview-1.jpg"},{id:143439,nr:2,picture:"https://images.pexels.com/videos/1542008/pictures/preview-2.jpg"},{id:143440,nr:3,picture:"https://images.pexels.com/videos/1542008/pictures/preview-3.jpg"},{id:143441,nr:4,picture:"https://images.pexels.com/videos/1542008/pictures/preview-4.jpg"},{id:143442,nr:5,picture:"https://images.pexels.com/videos/1542008/pictures/preview-5.jpg"},{id:143443,nr:6,picture:"https://images.pexels.com/videos/1542008/pictures/preview-6.jpg"},{id:143444,nr:7,picture:"https://images.pexels.com/videos/1542008/pictures/preview-7.jpg"},{id:143445,nr:8,picture:"https://images.pexels.com/videos/1542008/pictures/preview-8.jpg"},{id:143446,nr:9,picture:"https://images.pexels.com/videos/1542008/pictures/preview-9.jpg"},{id:143447,nr:10,picture:"https://images.pexels.com/videos/1542008/pictures/preview-10.jpg"},{id:143448,nr:11,picture:"https://images.pexels.com/videos/1542008/pictures/preview-11.jpg"},{id:143449,nr:12,picture:"https://images.pexels.com/videos/1542008/pictures/preview-12.jpg"},{id:143450,nr:13,picture:"https://images.pexels.com/videos/1542008/pictures/preview-13.jpg"},{id:143451,nr:14,picture:"https://images.pexels.com/videos/1542008/pictures/preview-14.jpg"}]},{id:5562986,width:3840,height:2160,duration:19,full_res:null,tags:[],url:"https://www.pexels.com/video/aerial-footage-of-foggy-area-5562986/",image:"https://images.pexels.com/videos/5562986/4k-video-autumn-autumn-atmosphere-autumn-color-5562986.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:649765,name:"Yaroslav Shuraev",url:"https://www.pexels.com/@yaroslav-shuraev"},video_files:[{id:9732341,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:24,link:"https://videos.pexels.com/video-files/5562986/5562986-sd_426_240_24fps.mp4"},{id:9732370,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:24,link:"https://videos.pexels.com/video-files/5562986/5562986-hd_1280_720_24fps.mp4"},{id:9732404,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:24,link:"https://videos.pexels.com/video-files/5562986/5562986-sd_640_360_24fps.mp4"},{id:9732439,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:24,link:"https://videos.pexels.com/video-files/5562986/5562986-sd_960_540_24fps.mp4"},{id:9732459,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:24,link:"https://videos.pexels.com/video-files/5562986/5562986-uhd_3840_2160_24fps.mp4"},{id:9732488,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:24,link:"https://videos.pexels.com/video-files/5562986/5562986-uhd_2560_1440_24fps.mp4"},{id:9732524,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:24,link:"https://videos.pexels.com/video-files/5562986/5562986-hd_1920_1080_24fps.mp4"}],video_pictures:[{id:3012615,nr:0,picture:"https://images.pexels.com/videos/5562986/pictures/preview-0.jpg"},{id:3012625,nr:1,picture:"https://images.pexels.com/videos/5562986/pictures/preview-1.jpg"},{id:3012649,nr:2,picture:"https://images.pexels.com/videos/5562986/pictures/preview-2.jpg"},{id:3012657,nr:3,picture:"https://images.pexels.com/videos/5562986/pictures/preview-3.jpg"},{id:3012664,nr:4,picture:"https://images.pexels.com/videos/5562986/pictures/preview-4.jpg"},{id:3012675,nr:5,picture:"https://images.pexels.com/videos/5562986/pictures/preview-5.jpg"},{id:3012678,nr:6,picture:"https://images.pexels.com/videos/5562986/pictures/preview-6.jpg"},{id:3012685,nr:7,picture:"https://images.pexels.com/videos/5562986/pictures/preview-7.jpg"},{id:3012692,nr:8,picture:"https://images.pexels.com/videos/5562986/pictures/preview-8.jpg"},{id:3012696,nr:9,picture:"https://images.pexels.com/videos/5562986/pictures/preview-9.jpg"},{id:3012700,nr:10,picture:"https://images.pexels.com/videos/5562986/pictures/preview-10.jpg"},{id:3012707,nr:11,picture:"https://images.pexels.com/videos/5562986/pictures/preview-11.jpg"},{id:3012713,nr:12,picture:"https://images.pexels.com/videos/5562986/pictures/preview-12.jpg"},{id:3012718,nr:13,picture:"https://images.pexels.com/videos/5562986/pictures/preview-13.jpg"},{id:3012725,nr:14,picture:"https://images.pexels.com/videos/5562986/pictures/preview-14.jpg"}]},{id:8859849,width:2160,height:3840,duration:22,full_res:null,tags:[],url:"https://www.pexels.com/video/video-of-cascading-waterfall-8859849/",image:"https://images.pexels.com/videos/8859849/acrobatics-cliff-exercises-fitness-8859849.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=1200&w=630",avg_color:null,user:{id:2297095,name:"Pavel Danilyuk",url:"https://www.pexels.com/@pavel-danilyuk"},video_files:[{id:10975993,quality:"uhd",file_type:"video/mp4",width:2160,height:3840,fps:25,link:"https://videos.pexels.com/video-files/8859849/8859849-uhd_2160_3840_25fps.mp4"},{id:10976039,quality:"sd",file_type:"video/mp4",width:360,height:640,fps:25,link:"https://videos.pexels.com/video-files/8859849/8859849-sd_360_640_25fps.mp4"},{id:10976089,quality:"hd",file_type:"video/mp4",width:1080,height:1920,fps:25,link:"https://videos.pexels.com/video-files/8859849/8859849-hd_1080_1920_25fps.mp4"},{id:10976142,quality:"hd",file_type:"video/mp4",width:720,height:1280,fps:25,link:"https://videos.pexels.com/video-files/8859849/8859849-hd_720_1280_25fps.mp4"},{id:10976188,quality:"sd",file_type:"video/mp4",width:540,height:960,fps:25,link:"https://videos.pexels.com/video-files/8859849/8859849-sd_540_960_25fps.mp4"},{id:10976235,quality:"uhd",file_type:"video/mp4",width:1440,height:2560,fps:25,link:"https://videos.pexels.com/video-files/8859849/8859849-uhd_1440_2560_25fps.mp4"},{id:10976270,quality:"sd",file_type:"video/mp4",width:240,height:426,fps:25,link:"https://videos.pexels.com/video-files/8859849/8859849-sd_240_426_25fps.mp4"}],video_pictures:[{id:8943680,nr:0,picture:"https://images.pexels.com/videos/8859849/pictures/preview-0.jpeg"},{id:8943684,nr:1,picture:"https://images.pexels.com/videos/8859849/pictures/preview-1.jpeg"},{id:8943688,nr:2,picture:"https://images.pexels.com/videos/8859849/pictures/preview-2.jpeg"},{id:8943691,nr:3,picture:"https://images.pexels.com/videos/8859849/pictures/preview-3.jpeg"},{id:8943697,nr:4,picture:"https://images.pexels.com/videos/8859849/pictures/preview-4.jpeg"},{id:8943705,nr:5,picture:"https://images.pexels.com/videos/8859849/pictures/preview-5.jpeg"},{id:8943712,nr:6,picture:"https://images.pexels.com/videos/8859849/pictures/preview-6.jpeg"},{id:8943719,nr:7,picture:"https://images.pexels.com/videos/8859849/pictures/preview-7.jpeg"},{id:8943728,nr:8,picture:"https://images.pexels.com/videos/8859849/pictures/preview-8.jpeg"},{id:8943743,nr:9,picture:"https://images.pexels.com/videos/8859849/pictures/preview-9.jpeg"},{id:8943754,nr:10,picture:"https://images.pexels.com/videos/8859849/pictures/preview-10.jpeg"},{id:8943761,nr:11,picture:"https://images.pexels.com/videos/8859849/pictures/preview-11.jpeg"},{id:8943766,nr:12,picture:"https://images.pexels.com/videos/8859849/pictures/preview-12.jpeg"},{id:8943774,nr:13,picture:"https://images.pexels.com/videos/8859849/pictures/preview-13.jpeg"},{id:8943781,nr:14,picture:"https://images.pexels.com/videos/8859849/pictures/preview-14.jpeg"}]},{id:4125029,width:3840,height:2160,duration:10,full_res:null,tags:[],url:"https://www.pexels.com/video/mountains-summer-travel-camping-4125029/",image:"https://images.pexels.com/videos/4125029/pexels-photo-4125029.jpeg?auto=compress&cs=tinysrgb&fit=crop&h=630&w=1200",avg_color:null,user:{id:649765,name:"Yaroslav Shuraev",url:"https://www.pexels.com/@yaroslav-shuraev"},video_files:[{id:9350181,quality:"uhd",file_type:"video/mp4",width:3840,height:2160,fps:23.976,link:"https://videos.pexels.com/video-files/4125029/4125029-uhd_3840_2160_24fps.mp4"},{id:9350206,quality:"sd",file_type:"video/mp4",width:960,height:540,fps:23.976,link:"https://videos.pexels.com/video-files/4125029/4125029-sd_960_540_24fps.mp4"},{id:9350241,quality:"hd",file_type:"video/mp4",width:1920,height:1080,fps:23.976,link:"https://videos.pexels.com/video-files/4125029/4125029-hd_1920_1080_24fps.mp4"},{id:9350263,quality:"sd",file_type:"video/mp4",width:426,height:240,fps:23.976,link:"https://videos.pexels.com/video-files/4125029/4125029-sd_426_240_24fps.mp4"},{id:9350306,quality:"uhd",file_type:"video/mp4",width:2560,height:1440,fps:23.976,link:"https://videos.pexels.com/video-files/4125029/4125029-uhd_2560_1440_24fps.mp4"},{id:9350344,quality:"hd",file_type:"video/mp4",width:1280,height:720,fps:23.976,link:"https://videos.pexels.com/video-files/4125029/4125029-hd_1280_720_24fps.mp4"},{id:9350383,quality:"sd",file_type:"video/mp4",width:640,height:360,fps:23.976,link:"https://videos.pexels.com/video-files/4125029/4125029-sd_640_360_24fps.mp4"}],video_pictures:[{id:1184997,nr:0,picture:"https://images.pexels.com/videos/4125029/pictures/preview-0.jpg"},{id:1185002,nr:1,picture:"https://images.pexels.com/videos/4125029/pictures/preview-1.jpg"},{id:1185007,nr:2,picture:"https://images.pexels.com/videos/4125029/pictures/preview-2.jpg"},{id:1185012,nr:3,picture:"https://images.pexels.com/videos/4125029/pictures/preview-3.jpg"},{id:1185017,nr:4,picture:"https://images.pexels.com/videos/4125029/pictures/preview-4.jpg"},{id:1185021,nr:5,picture:"https://images.pexels.com/videos/4125029/pictures/preview-5.jpg"},{id:1185025,nr:6,picture:"https://images.pexels.com/videos/4125029/pictures/preview-6.jpg"},{id:1185028,nr:7,picture:"https://images.pexels.com/videos/4125029/pictures/preview-7.jpg"},{id:1185032,nr:8,picture:"https://images.pexels.com/videos/4125029/pictures/preview-8.jpg"},{id:1185037,nr:9,picture:"https://images.pexels.com/videos/4125029/pictures/preview-9.jpg"},{id:1185041,nr:10,picture:"https://images.pexels.com/videos/4125029/pictures/preview-10.jpg"},{id:1185044,nr:11,picture:"https://images.pexels.com/videos/4125029/pictures/preview-11.jpg"},{id:1185046,nr:12,picture:"https://images.pexels.com/videos/4125029/pictures/preview-12.jpg"},{id:1185047,nr:13,picture:"https://images.pexels.com/videos/4125029/pictures/preview-13.jpg"},{id:1185048,nr:14,picture:"https://images.pexels.com/videos/4125029/pictures/preview-14.jpg"}]}],mI="https://builder-backend.hostinger.com/pexels",UF=async({query:t,page:e,perPage:o})=>{const{data:n}=await Ut.post(`${mI}/search`,{query:t,page:e,perPage:o});return n},jF=async({id:t})=>{const{data:e}=await Ut.post(`${mI}/search/${t}`);return e},A_={searchVideos:UF,searchVideoById:jF},zu=t=>t.map(e=>({id:e.id,image:e.image,user:e.user,videoFiles:e==null?void 0:e.video_files.map(o=>({id:o.id,quality:o.quality,width:o.width,height:o.height,link:o.link}))})),hI=t=>t.sort((e,o)=>j1.indexOf(o.quality)-j1.indexOf(e.quality))[0],WF=Wo("pexels",()=>{const{state:t,dispatch:e}=nt(),{notify:o}=Le(),{t:n}=_t(),s=C(zu(uc)),a=C("Nature"),l=C(1),i=C(!1),r=c(()=>t.currentBlockId),u=c(()=>!i.value&&(!s.value.length||!a.value.length)),p=async({query:k,page:I})=>{var P;if(i.value=!0,I||(l.value=1),a.value=k.trim(),typeof k!="string"||!k.trim().length){s.value=[],i.value=!1;return}const E=(P=uB.exec(k))==null?void 0:P[1],T=!!k.trim().match(/^\d+$/);try{const z=[];if(T||E){const L=await A_.searchVideoById({id:Number.parseInt(E||k,10)});L&&z.push(L)}else{const{videos:L}=await A_.searchVideos({query:k,perPage:TA,page:l.value});z.push(...L)}if(I&&I!==1){s.value=[...s.value,...zu(z)],i.value=!1;return}s.value=zu(z),i.value=!1}catch{throw i.value=!1,o({message:n("builder.pexelsSearchFailed")}),new Error("Failed to search for videos")}};return{searchVideo:p,searchMoreVideos:async()=>{s.value.length!==1&&(l.value+=1,await p({query:a.value,page:l.value}))},selectVideo:k=>{const I=s.value.find(z=>z.id===k);if(!I)throw o({message:n("builder.pexelsInvalidSelectedVideo")}),new Error(`Video with id ${k} not found`);const E=I.image,T=hI(I.videoFiles),P=T==null?void 0:T.link;if(!P)throw o({message:n("builder.pexelsMissingVideoURL")}),new Error("Failed to get video resource URL");e("updateBlockData",{blockId:r.value,blockData:{background:{current:"video",video:{videoSrc:P,videoThumbnailSrc:E}}},merge:!0}),Et.logEvent({eventName:"website_builder.section_settings.section_background_change",eventProperties:{type:Me.VIDEO}})},setDefaultPexelsVideos:()=>{s.value=zu(uc),a.value="Nature"},videos:s,showEmptyDisclaimer:u}}),qF={class:"video-preview"},YF={class:"video-preview__video-container"},KF=["src","poster"],ZF={class:"video-preview__author-container"},QF={class:"video-preview__author text-body-2"},XF=["href"],JF={class:"z-link",href:"https://www.pexels.com/terms-of-service/",target:"_blank",rel:"noopener noreferrer"},tV=q({__name:"PexelsVideoPreview",props:{video:{}},emits:["select-video"],setup(t,{emit:e}){const o=e,n=t,{t:s}=_t(),a=hI(n.video.videoFiles),l=C(!1);return(i,r)=>{const u=G("i18n-t");return d(),v("div",qF,[m("div",YF,[l.value?B("",!0):(d(),S(Ue,{key:0,size:"32px",color:"var(--color-light)",class:"video-preview__loader"})),m("video",{src:f(a).link,autoplay:"",muted:"",loop:"",class:"video-preview__video",poster:n.video.image,onLoadeddata:r[0]||(r[0]=p=>l.value=!0)},null,40,KF)]),m("div",ZF,[m("div",QF,[m("p",null,[h(u,{class:"video-preview__author text-body-2",keypath:"builder.assetManagerTabPexelsFootageAuthor"},{default:_(()=>[m("a",{class:"z-link",href:n.video.user.url,target:"_blank",rel:"noopener noreferrer"},w(n.video.user.name)+". ",9,XF)]),_:1})]),m("p",null,[h(u,{class:"video-preview__author-name",keypath:"builder.assetManagerTabPexelsAccreditation"},{default:_(()=>[m("a",JF,w(i.$t("builder.assetManagerTabPexelsAccreditationLink")),1)]),_:1})]),h(ut,{title:f(s)("builder.assetManagerMediaLayoutSelectItem"),onClick:r[1]||(r[1]=p=>o("select-video",n.video.id))},{default:_(()=>[j(w(f(s)("builder.assetManagerMediaLayoutSelectItem")),1)]),_:1},8,["title"])])])])}}}),eV={key:0,class:"free-videos__disclaimer-container"},oV={class:"text-heading-1"},nV={class:"text-body-2"},iV={class:"free-videos__list"},sV=["src","onClick"],aV={key:2,class:"free-videos__pexels-attribution"},lV=q({__name:"PexelsLayout",props:Ib({isPreviewOpen:{type:Boolean}},{searchQuery:{type:String,default:""},searchQueryModifiers:{}}),emits:Ib(["toggle-preview","close"],["update:searchQuery"]),setup(t,{emit:e}){const o=e,{t:n}=_t(),s=WF(),a=Hf(t,"searchQuery"),l=C(),{arrivedState:i}=x5(l),{bottom:r}=hc(i),u=C(),p=y=>{u.value=y,o("toggle-preview",!0)},g=()=>{u.value=void 0,o("toggle-preview",!1)},b=y=>{s.selectVideo(y),o("close")};return Rt(r,y=>{y&&s.searchMoreVideos()}),Rt(a,Rx(()=>s.searchVideo({query:a.value}),CA)),Nt(()=>{s.showEmptyDisclaimer&&s.setDefaultPexelsVideos()}),(y,k)=>(d(),v(dt,null,[y.isPreviewOpen?(d(),S(tV,{key:0,video:u.value,onClosePreview:g,onSelectVideo:b},null,8,["video"])):(d(),v(dt,{key:1},[h(bs,{modelValue:a.value,"onUpdate:modelValue":k[0]||(k[0]=I=>a.value=I),class:"free-videos__search-input",placeholder:"Search for free videos"},null,8,["modelValue"]),f(s).showEmptyDisclaimer?(d(),v("div",eV,[m("span",oV,w(f(n)("builder.assetManagerTabPexelsNoResults")),1),m("span",nV,w(f(n)("builder.assetManagerTabPexelsCheckSpelling")),1)])):(d(),v("div",{key:1,ref_key:"freeVideosRef",ref:l,class:"free-videos"},[m("div",null,[m("ul",iV,[(d(!0),v(dt,null,zt(f(s).videos,I=>(d(),v("li",{key:I.id,class:"free-videos__item"},[m("img",{class:"free-videos__image",src:I.image,alt:"video",onClick:E=>p(I)},null,8,sV)]))),128))])])],512))],64)),y.isPreviewOpen?B("",!0):(d(),v("div",aV,[h(Cn,{class:"free-videos__pexels-logo",src:"/images/pexels-logo.png"})]))],64))}}),rV=H(lV,[["__scopeId","data-v-a7be9721"]]),dV=[Oo.MY_LIBRARY,Oo.IMAGES,Oo.AI_IMAGES,Oo.DOCUMENTS],cV=q({components:{Icon:lt,HostingerButton:ut,ZyroModal:je,ZyroSvgDeprecated:qt,ZyroTabs:xl,GalleryManager:zN,SlideshowManager:ON,UnsplashLayout:pG,AssetsLayout:VF,AssetDetailsLayout:RG,AssetManagerGoBackButton:uI,PexelsLayout:rV},props:{isSlideshow:{type:Boolean,default:!1},slideshowId:{type:String,default:null},isGallery:{type:Boolean,default:!1},galleryId:{type:String,default:null},visibleCategories:{type:Array,default:()=>cc,validator:t=>t.every(e=>cc.includes(e))},isAssetSelectButtonHidden:{type:Boolean,default:!1}},emits:["select-image","select-images","update-target","close"],setup(t){const{dispatch:e}=nt(),{onSelectFiles:o,assets:n,deselectSelectedGalleryImages:s,isDeleteAssetModalOpened:a,assetsToDelete:l,folderToDelete:i}=Ss(t),{addNewFolder:r,currentDirectory:u,moveFileTo:p,setAssetName:g,setImageAltTag:b,validAssetsWithPaths:y,assetPaths:k}=im({assets:n}),{isAiBuilderMode:I}=vo(),{t:E}=_t(),T=C(!1),P=C(!1),z=t.visibleCategories.includes(Bo.IMAGE),L=t.visibleCategories.includes(Bo.VIDEO),D=()=>t.isAssetSelectButtonHidden||L?[]:[{isDisabled:!z,title:E("builder.assetManagerTabFreeImages"),id:Oo.UNSPLASH}],$=()=>I.value?[{title:E("builder.assetManagerTabMyLibrary"),id:Oo.MY_LIBRARY_PAYWALL},{title:E("builder.assetManagerTabImages"),id:Oo.MY_LIBRARY_PAYWALL,isDisabled:!z},{title:E("builder.assetManagerTabDocuments"),id:Oo.MY_LIBRARY_PAYWALL}]:L?[{isDisabled:!1,title:"Free videos",id:Oo.PEXELS}]:[{title:E("builder.assetManagerTabMyLibrary"),id:Oo.MY_LIBRARY},{title:E("builder.assetManagerTabImages"),id:Oo.IMAGES,isDisabled:!z},{title:E("builder.aiImageGenerationAssetManagerTabName"),id:Oo.AI_IMAGES,isDisabled:!z},{title:E("builder.assetManagerTabDocuments"),id:Oo.DOCUMENTS}],A=D(),M=$(),U=c(()=>!I.value&&!L),Y=c(()=>I.value?A[0]:M[0]),F=X=>e("assets/setCurrentDirectory",X),W=()=>{P.value=!1,T.value=!0,F("/")},V=({newPath:X,asset:et})=>{const pt=Ia(et.url);p({id:pt,path:et.path,newPath:X})},K=X=>{const et=X.path.endsWith("/");a.value=!0,et?(i.value=X,l.value=My({directory:X.path,assets:n.value,assetPaths:k.value,includeFromSubfolders:!0})):l.value=[X]},Z=({asset:X,newName:et})=>{!et||et===X.name||g({newName:et,id:X.id})},N=({asset:X,newAltTag:et})=>{b({newAltTag:et,id:X.id})};return s(),{DATA_ATTRIBUTE_SELECTOR:ko,DATA_ATTRIBUTE_SELECTOR_ASSET_MANAGER:Od,tabsLeft:M,tabsRight:A,onSelectFiles:o,assets:n,isBackButtonVisible:P,isGalleryManagerOpen:T,deselectSelectedGalleryImages:s,addNewFolder:r,currentDirectory:u,setCurrentDirectory:F,handleMoveClick:V,handleDeleteClick:K,handleRenameClick:Z,updateImgAltTag:N,validAssetsWithPaths:y,handleBackButtonClick:W,DATA_PORTAL_ASSET_MANAGER:l3,defaultTab:Y,isAiBuilderMode:I,isUploadButtonVisible:U,isVideosTabEnabled:L,ASSETS_TAB_ID:Oo}},data(){return{assetBeingViewed:null,isSlideshowManagerOpen:this.isSlideshow,currentTab:null,selectedGalleryImages:[]}},computed:{...Ae(["websiteId"]),validAssets(){return this.assets.filter(t=>!t.hasFailed)},documentAssets(){return this.validAssets.filter(Hy)},imageAssets(){return this.validAssets.filter(cs)},visibleAssets(){return this.currentTab.id===Oo.DOCUMENTS?this.documentAssets:this.currentTab.id===Oo.IMAGES?this.imageAssets:this.validAssets},isAssetBeingViewed(){return!!this.assetBeingViewed},title(){return this.isGalleryManagerOpen?this.$t("builder.assetManagerGalleryGallery"):this.isSlideshowManagerOpen?this.$t("builder.assetManagerSlideshowSlideshow"):this.isVideosTabEnabled?this.$t("builder.assetManagerVideoLibrary"):this.$t("builder.assetManagerMediaLibrary")},isAssetsLayoutVisible(){return this.currentTab?dV.includes(this.currentTab.id):!0}},created(){this.currentTab=this.defaultTab,this.isGalleryManagerOpen=this.isGallery,Et.logEvent({eventName:"website_builder.asset_manager.enter"})},methods:{...be("assets",["setCurrentDirectory"]),async selectImage(t){var i,r;const e=this.currentTab.id===Oo.UNSPLASH;let o="",n="";if(e?((i=t==null?void 0:t.links)!=null&&i.download_location&&eG({imageJson:t}),o=`${t.urls.raw}${rA}`,n=t.alt_description):(o=t,n=((r=this.validAssetsWithPaths.find(u=>u.url===t))==null?void 0:r.altTag)||""),!o)return;this.isGallery&&(this.isGalleryManagerOpen=!0,this.resetState()),this.isSlideshow&&(this.isSlideshowManagerOpen=!0,this.resetState()),Se({category:"SELECT_IMAGE",data:{imageUrl:o,isGallery:this.isGallery,isUnsplash:e},level:"debug",type:"debug"}),this.setCurrentDirectory("/");const{origin:s,path:a}=w_(o),l=En(a);if(t.category&&t.category===Bo.IMAGE&&this.$emit("update-target","_blank"),U0.includes(l))try{const p=Hr(o)?`generated/${a}`:a,g=Mr(s,p,this.websiteId),{naturalWidth:b,naturalHeight:y}=await dI(g);this.$emit("select-image",{fullResolutionWidth:b,fullResolutionHeight:y,origin:s,path:a,url:o,alt:n});return}catch{this.$store.dispatch("notifications/notify",{messageI18nKeyPath:"builder.assetFailedToLoad"});return}this.$emit("select-image",{origin:s,path:a,url:o,alt:n})},addSelectedImagesToGallery(){const t=this.assets.filter(e=>e.isGalleryImageSelected&&e.url).map(({url:e})=>({url:e,...w_(e),alt:""}));this.$emit("select-images",t),this.isGalleryManagerOpen=!0,this.resetState()},resetState(){this.currentTab=this.defaultTab,this.assetBeingViewed=null,this.isBackButtonVisible=!1,this.setCurrentDirectory("/"),this.deselectSelectedGalleryImages()},handleCloseModal(){this.$emit("close"),this.setCurrentDirectory("/"),this.isDeleteAssetModalOpened=!1}}}),uV={class:"asset-manager__navigation"},pV={key:2,class:"asset-manager__tab-navigation"},gV={key:0,class:"asset-manager__tabs"},mV={key:0,class:"asset-manager__separator"},hV={class:"asset-manager__buttons"},bV={key:2,class:"asset-manager__paywall-wrapper"},fV={class:"asset-manager__paywall-container"},yV={class:"asset-manager__paywall-heading"},vV={class:"asset-manager__paywall-copy"};function _V(t,e,o,n,s,a){const l=G("GalleryManager"),i=G("SlideshowManager"),r=G("AssetManagerGoBackButton"),u=G("ZyroSvgDeprecated"),p=G("HostingerButton"),g=G("ZyroTabs"),b=G("Icon"),y=G("AssetDetailsLayout"),k=G("AssetsLayout"),I=G("PexelsLayout"),E=G("UnsplashLayout"),T=G("ZyroModal"),P=ct("qa");return d(),S(T,Fe({"max-width":"1200px","max-height":"90vh",title:t.title,"content-padding":"0","no-overflow":"","use-flex-for-content":"",class:["asset-manager",{"asset-manager--ai-builder":t.isAiBuilderMode}],[t.DATA_ATTRIBUTE_SELECTOR||""]:t.DATA_ATTRIBUTE_SELECTOR_ASSET_MANAGER,"data-portal":t.DATA_PORTAL_ASSET_MANAGER,onCloseModal:t.handleCloseModal}),{default:_(()=>[t.isGalleryManagerOpen?(d(),S(l,{key:0,"gallery-id":t.galleryId,onOpenAssetManager:e[0]||(e[0]=z=>t.isGalleryManagerOpen=!1)},null,8,["gallery-id"])):t.isSlideshowManagerOpen?(d(),S(i,{key:1,"slideshow-id":t.slideshowId,onOpenAssetManager:e[1]||(e[1]=z=>t.isSlideshowManagerOpen=!1)},null,8,["slideshow-id"])):(d(),v(dt,{key:2},[O(m("div",uV,[t.galleryId?(d(),S(r,{key:0,onButtonClick:t.handleBackButtonClick},null,8,["onButtonClick"])):B("",!0),t.isBackButtonVisible?O((d(),S(p,{key:1,class:"asset-manager__back-button","button-type":"text",onClick:e[2]||(e[2]=z=>t.isBackButtonVisible=!1)},{"icon-left":_(()=>[h(u,{name:"chevron",direction:"left"})]),default:_(()=>[j(" "+w(t.$t("builder.assetManagerBackToList")),1)]),_:1})),[[P,"asset-manager-back-button"]]):(d(),v("div",pV,[t.isVideosTabEnabled?B("",!0):(d(),v("div",gV,[m("div",null,[t.tabsLeft.length?(d(),S(g,{key:0,tabs:t.tabsLeft,"current-tab":t.currentTab,"onUpdate:currentTab":e[3]||(e[3]=z=>t.currentTab=z)},null,8,["tabs","current-tab"])):B("",!0)]),t.tabsRight.length&&t.tabsLeft.length?(d(),v("span",mV)):B("",!0),m("div",null,[h(g,{tabs:t.tabsRight,"current-tab":t.currentTab,class:"asset-manager__right-tabs","onUpdate:currentTab":e[4]||(e[4]=z=>t.currentTab=z)},null,8,["tabs","current-tab"])])])),m("div",hV,[t.currentTab.id===t.ASSETS_TAB_ID.MY_LIBRARY?O((d(),S(p,{key:0,"button-type":"text",onClick:t.addNewFolder},{"icon-left":_(()=>[h(b,{name:"folder-plus",dimensions:"20px","is-custom":""})]),default:_(()=>[j(" "+w(t.$t("builder.foldersCreateFolder")),1)]),_:1},8,["onClick"])),[[P,"assetmanager-create-folder"]]):B("",!0),t.isUploadButtonVisible?O((d(),S(p,{key:1,class:"asset-manager__upload-button",onClick:e[5]||(e[5]=z=>t.$refs.fileInput.click())},{"icon-left":_(()=>[h(b,{name:"upload",dimensions:"20px"})]),default:_(()=>[j(" "+w(t.$t("builder.assetManagerTabUserUploadFiles")),1)]),_:1})),[[P,"assetmanager-uploadimage"]]):B("",!0)])]))],512),[[Qe,!t.isAssetBeingViewed]]),t.isAssetBeingViewed?(d(),S(y,{key:0,asset:t.assetBeingViewed,"is-asset-select-button-hidden":t.isAssetSelectButtonHidden,onSelectAsset:t.selectImage,onUpdateImgAltTag:t.updateImgAltTag,onClose:e[6]||(e[6]=z=>t.assetBeingViewed=null)},null,8,["asset","is-asset-select-button-hidden","onSelectAsset","onUpdateImgAltTag"])):(d(),v(dt,{key:1},[O(h(k,{"is-gallery":t.isGallery,"valid-assets":t.visibleAssets,"current-tab":t.currentTab,"visible-categories":t.visibleCategories,"is-asset-select-button-hidden":t.isAssetSelectButtonHidden,onOpenImageDetails:e[7]||(e[7]=z=>t.assetBeingViewed=z),onOpenFileDialog:e[8]||(e[8]=z=>t.$refs.fileInput.click()),onSelectImage:t.selectImage,onAddToGallery:t.addSelectedImagesToGallery,onOpenDirectory:t.setCurrentDirectory,onMoveAssetTo:t.handleMoveClick,onDeleteAsset:t.handleDeleteClick,onRenameAsset:t.handleRenameClick},null,8,["is-gallery","valid-assets","current-tab","visible-categories","is-asset-select-button-hidden","onSelectImage","onAddToGallery","onOpenDirectory","onMoveAssetTo","onDeleteAsset","onRenameAsset"]),[[Qe,t.isAssetsLayoutVisible]]),t.currentTab.id===t.ASSETS_TAB_ID.PEXELS?(d(),S(I,{key:0,"is-preview-open":t.isBackButtonVisible,onTogglePreview:e[9]||(e[9]=z=>t.isBackButtonVisible=z),onClose:e[10]||(e[10]=z=>t.$emit("close"))},null,8,["is-preview-open"])):t.currentTab.id===t.ASSETS_TAB_ID.UNSPLASH?(d(),S(E,{key:1,"is-preview-open":t.isBackButtonVisible,"is-gallery":t.isGallery,onTogglePreview:e[11]||(e[11]=z=>t.isBackButtonVisible=z),onSelectImage:t.selectImage},null,8,["is-preview-open","is-gallery","onSelectImage"])):B("",!0),t.currentTab.id===t.ASSETS_TAB_ID.MY_LIBRARY_PAYWALL?(d(),v("div",bV,[m("div",fV,[h(b,{name:"lock"}),m("h2",yV,w(t.$t("builder.aiPaywallHeading")),1),m("p",vV,w(t.$t("builder.aiPaywallCopy")),1)])])):B("",!0)],64))],64)),O(m("input",{ref:"fileInput",type:"file",name:"images",multiple:"",onChange:e[12]||(e[12]=z=>t.onSelectFiles(z))},null,544),[[Qe,!1],[P,"builder-input-image"]])]),_:1},16,["title","class","data-portal","onCloseModal"])}const Ra=H(cV,[["render",_V],["__scopeId","data-v-a5577e76"]]),wV={class:"video-selector"},kV=["title"],IV=["src"],SV={class:"video-selector__description"},EV={class:"text-body-2"},xV=q({__name:"VideoSelector",setup(t){const{getters:e}=nt(),{t:o}=_t(),n=C(!1),s=c(()=>e.currentBlock),a=c(()=>{var r,u,p;return((u=(r=s.value.background)==null?void 0:r.video)==null?void 0:u.videoThumbnailSrc)||((p=uc[0])==null?void 0:p.image)}),l=c(()=>a.value?o("common.replaceVideo"):o("common.addVideo")),i=()=>{n.value=!0};return(r,u)=>{const p=ct("qa");return d(),v("div",wV,[O((d(),v("button",{class:"video-selector__button",title:l.value,onClick:i},[a.value?(d(),v("img",{key:0,src:a.value,alt:"",class:"video-selector__image"},null,8,IV)):B("",!0),m("div",SV,[h(lt,{name:"video_library",class:"video-selector__icon"}),m("p",EV,w(l.value),1)])],8,kV)),[[p,"builder-sectionsettings-btn-addvideo"]]),n.value?(d(),S(Ee,{key:0,to:"body"},[h(Ra,{"visible-categories":[f(Bo).VIDEO],onClose:u[0]||(u[0]=g=>n.value=!1)},null,8,["visible-categories"])])):B("",!0)])}}}),TV=H(xV,[["__scopeId","data-v-4b5c7e31"]]),CV=["title"],PV=["src"],BV=["innerHTML"],AV={class:"zyro-image-selector__description"},DV={class:"text-body-2"},zV=400,$V=200,LV=q({__name:"ZyroImageSelector",props:{origin:{default:null},path:{default:""},objectFit:{default:"contain"},logoSvg:{default:null}},emits:["update"],setup(t,{emit:e}){const o=t,n=e,{state:s}=nt(),{t:a}=_t(),l=C(!1),i=c(()=>s.websiteId),r=c(()=>jo(o.origin,o.path,i.value,{isLossless:!0,width:zV,height:$V,shouldContain:o.objectFit==="contain"})),u=c(()=>({"--z-object-fit":o.objectFit||void 0})),p=c(()=>r.value?a("common.replaceImage"):a("common.addImage")),g=()=>{l.value=!0},b=y=>{l.value=!1,n("update",y)};return(y,k)=>{const I=ct("qa");return d(),v("div",{class:"zyro-image-selector",style:ne(u.value)},[O((d(),v("button",{class:"zyro-image-selector__button",title:p.value,onClick:g},[r.value?(d(),v("img",{key:0,src:r.value,alt:"",class:"zyro-image-selector__image"},null,8,PV)):o.logoSvg?(d(),v("div",{key:1,class:"zyro-image-selector__image--svg",innerHTML:o.logoSvg},null,8,BV)):B("",!0),m("div",AV,[h(lt,{name:"photo_library",class:"zyro-image-selector__icon"}),m("p",DV,w(p.value),1)])],8,CV)),[[I,"builder-sectionsettings-btn-addimage"]]),l.value?(d(),S(Ee,{key:0,to:"body"},[h(Ra,{"visible-categories":[f(Bo).IMAGE],onSelectImage:b,onClose:k[0]||(k[0]=E=>l.value=!1)},null,8,["visible-categories"])])):B("",!0)],4)}}}),Ur=H(LV,[["__scopeId","data-v-b546c405"]]),Yy=q({props:{controls:{type:Array,required:!0,validator:t=>t.every(e=>"title"in e)},activeControl:{type:Object,required:!0,validator:t=>"title"in t},isBackgroundDark:{type:Boolean,default:!1}},emits:["update:active-control"],setup(t){const e=c(()=>t.controls.length),o=c(()=>t.controls.findIndex(n=>n.title===t.activeControl.title));return{numberOfControls:e,activeControlIndex:o}}}),D_=()=>{ue(t=>({"554d8cd5":t.numberOfControls,"6be806da":t.activeControlIndex}))},z_=Yy.setup;Yy.setup=z_?(t,e)=>(D_(),z_(t,e)):D_;const OV=t=>(ke("data-v-6c7cb1de"),t=t(),Ie(),t),RV=["onClick"],MV=OV(()=>m("div",{class:"zyro-segment-control__background"},null,-1));function HV(t,e,o,n,s,a){const l=ct("qa");return d(),v("div",{class:rt(["zyro-segment-control",{"zyro-segment-control--darker":t.isBackgroundDark}])},[(d(!0),v(dt,null,zt(t.controls,i=>O((d(),v("button",{key:i.title,class:rt([{"zyro-segment-control__button--active":i.title===t.activeControl.title},"zyro-segment-control__button text-body-2"]),onClick:r=>t.$emit("update:active-control",i)},[j(w(i.title),1)],10,RV)),[[l,`builder-sectionsettings-tab-${i.title}`]])),128)),MV],2)}const Fi=H(Yy,[["render",HV],["__scopeId","data-v-6c7cb1de"]]),NV={key:0,class:"zyro-background-selector"},GV=q({__name:"ZyroBackground",props:{isSegmentControlBackgroundDark:{type:Boolean,default:!1},isOpacityDisabled:{type:Boolean,default:!1}},setup(t){var U;const e=t,{t:o}=_t(),{completeAchievement:n}=Ho(),{getters:s,dispatch:a,state:l}=nt(),i=c(()=>l.currentBlockId),r=c(()=>s.currentBlock.type===Lr),u=c(()=>s.currentBlock.background),p=c(()=>{var Y;return((Y=u.value)==null?void 0:Y.current)===Me.GRADIENT?Me.GRADIENT:Me.COLOR}),g=c(()=>[{title:o("common.color"),id:p.value,localId:Me.COLOR},{title:o("common.image"),id:Me.IMAGE},...r.value?[]:[{title:o("common.video"),id:Me.VIDEO}]]),b=C(((U=u.value)==null?void 0:U.current)||Me.COLOR),y=C(!1),k=c(()=>{var Y;return((Y=u.value)==null?void 0:Y.current)===Me.IMAGE}),I=c(()=>{var Y;return((Y=u.value)==null?void 0:Y.current)===Me.VIDEO}),E=c(()=>(k.value||I.value)&&!e.isOpacityDisabled),T=c(()=>{var Y,F;return(F=(Y=u.value)==null?void 0:Y.video)==null?void 0:F.videoSrc}),P=c(()=>g.value.find(Y=>Y.id===b.value)||g.value[0]),z=c(()=>{var Y;return(Y=u.value)!=null&&Y["overlay-opacity"]?Math.round(Number.parseFloat(u.value["overlay-opacity"])*100):0}),L=Y=>{a("updateBlockData",{blockId:i.value,blockData:{background:{...u.value,"overlay-opacity":`${(Y/100).toFixed(2)}`}},merge:!0})},D=Y=>{!g.value.find(W=>W.localId===Me.COLOR)||!u.value||(b.value=Me.GRADIENT,a("updateBlockData",{blockId:i.value,blockData:{background:{gradient:Y,color:void 0,current:Me.GRADIENT}},merge:!0}),Et.logEvent({eventName:"website_builder.section_settings.section_background_change",eventProperties:{type:Me.GRADIENT}}))},$=Y=>{!g.value.find(W=>W.localId===Me.COLOR)||!u.value||(b.value=Me.COLOR,a("updateBlockData",{blockId:i.value,blockData:{background:{color:Y,gradient:void 0,current:Me.COLOR}},merge:!0}),Et.logEvent({eventName:"website_builder.section_settings.section_background_change",eventProperties:{type:Me.COLOR}}))},A=({url:Y,origin:F,path:W,alt:V})=>{const K=Aa(Y,W);b.value=Me.IMAGE,a("updateBlockData",{blockId:i.value,blockData:{background:{image:Y,origin:F,path:K,current:Me.IMAGE,alt:V||void 0}},merge:!0}),Et.logEvent({eventName:"website_builder.section_settings.section_background_change",eventProperties:{type:Me.IMAGE}}),n(Ys)},M=Y=>{var W,V,K,Z;b.value=Y.id;const F={video:{videoSrc:(V=(W=uc[0])==null?void 0:W.video_files.at(-1))==null?void 0:V.link,videoThumbnailSrc:(K=uc[0])==null?void 0:K.image}};(Z=u.value)!=null&&Z.current&&a("updateBlockData",{blockId:i.value,blockData:{background:{current:Y.id,...Y.id===Me.VIDEO&&!T.value&&F}},merge:!0})};return(Y,F)=>{var V;const W=ct("qa");return(V=u.value)!=null&&V.current?(d(),v("div",NV,[h(Fi,{class:"zyro-background-selector__tabs",controls:g.value,"is-background-dark":Y.isSegmentControlBackgroundDark,"active-control":P.value,"onUpdate:activeControl":M},null,8,["controls","is-background-dark","active-control"]),["color","gradient"].includes(P.value.id)?(d(),S(Fo,{key:0,"has-gradient":"","is-open":y.value,label:Y.$t("builder.sectionColor"),color:u.value.color,gradient:u.value.gradient,current:u.value.current,placement:"left",class:"zyro-background-selector__color-picker","portal-selector":f(Ng),"is-opacity-disabled":Y.isOpacityDisabled,onUpdateColor:$,onUpdateGradient:D,onToggle:F[0]||(F[0]=K=>y.value=!y.value),onClickOutside:F[1]||(F[1]=K=>y.value=!1)},null,8,["is-open","label","color","gradient","current","portal-selector","is-opacity-disabled"])):B("",!0),I.value?(d(),S(TV,{key:1})):B("",!0),P.value.id===f(Me).IMAGE?(d(),S(Ur,{key:2,origin:u.value.origin,path:u.value.path,"object-fit":"contain",onUpdate:A},null,8,["origin","path"])):B("",!0),E.value?(d(),v(dt,{key:3},[h(Xt,{class:"background-overlay-label"},{default:_(()=>[j(w(Y.$t("builder.editBlockTabBackground.overlayOpacity")),1)]),_:1}),O(h(Jo,{"model-value":z.value,units:"%",min:"0",step:"1",max:"100","onUpdate:modelValue":L},null,8,["model-value"]),[[W,`backgroundsettings-overlayopacity-${z.value}`]])],64)):B("",!0)])):B("",!0)}}}),FV=H(GV,[["__scopeId","data-v-6197e74f"]]),VV={class:"zyro-field-toggle"},UV={class:"zyro-field-toggle__group"},jV={key:0,class:"zyro-field-toggle__message"},WV=q({__name:"ZyroFieldToggle",props:{id:{},label:{default:""},message:{default:""},modelValue:{type:Boolean},disabled:{type:Boolean,default:!1},qaSelector:{default:"toggle"}},emits:["update:model-value"],setup(t){const e=t;return(o,n)=>{const s=ct("qa");return d(),v("div",VV,[m("div",UV,[O((d(),S(Xt,{for:e.id,class:rt(["zyro-field-toggle__label",{"zyro-field-toggle__label--disabled":e.disabled}])},{default:_(()=>[vt(o.$slots,"icon-left",{},void 0,!0),j(" "+w(o.label),1)]),_:3},8,["for","class"])),[[s,"toggle-label"]]),O(h(Gn,{id:e.id,"model-value":e.modelValue,class:"zyro-field-toggle__switch",disabled:e.disabled,"onUpdate:modelValue":n[0]||(n[0]=a=>o.$emit("update:model-value",a))},null,8,["id","model-value","disabled"]),[[s,e.qaSelector]])]),o.message?(d(),v("div",jV,w(o.message),1)):B("",!0)])}}}),eo=H(WV,[["__scopeId","data-v-160acfb1"]]),qc=q({__name:"EditBlockTabBackground",props:{isFixedBackgroundDisabled:{type:Boolean,default:!1}},setup(t){const e=t,{getters:o,state:n,dispatch:s}=nt(),a=c(()=>n.currentBlockId),l=c(()=>o.currentBlock),i=c(()=>{const T={color:"rgb(255, 255, 255)",current:Me.COLOR};return l.value.background||T}),r=c(()=>l.value.attachment||yu.unset),u=c(()=>l.value.type===Lr),p=c(()=>i.value.current===Me.IMAGE),g=c(()=>i.value.current===Me.VIDEO),b=c(()=>r.value===yu.fixed),y=c(()=>!e.isFixedBackgroundDisabled&&(p.value||g.value)),k=c(()=>[yl,$r].includes(l.value.type)),I=T=>{s("updateBlockData",{blockId:a.value,blockData:{attachment:T},merge:!0})},E=T=>{I(T?yu.fixed:yu.unset)};return(T,P)=>(d(),v("div",null,[vt(T.$slots,"top"),h(FV,{"is-segment-control-background-dark":k.value,"is-opacity-disabled":u.value},null,8,["is-segment-control-background-dark","is-opacity-disabled"]),y.value?(d(),S(eo,{key:0,id:"backgroundAttachment",label:T.$t("common.fixedBackground"),"model-value":b.value,"onUpdate:modelValue":E},null,8,["label","model-value"])):B("",!0)]))}}),$_=C({}),qV=t=>{if(!t)return!1;const{top:e,bottom:o}=t.getBoundingClientRect();return e=0},bI=()=>({refs:$_,isElementVisibleOnScreen:e=>qV($_.value[e])}),YV=({element:t,elementTopOffset:e,newElementPosition:o,layoutElements:n,elementPositionKey:s})=>{const{elementId:a}=t,l=ey({layoutElements:n,activeElementId:a,elementPositionKey:s}),i=t[s].top-Os(o).top,r=Kp({topOffset:i,elementPositionKey:s,lowerElementsRelativeToActive:l}),u=Zp({elementsPositions:{...r},topOffset:e,elementPositionKey:s});return a?{...u,[a]:{[s]:o}}:{...u}},KV=({blockElements:t,activeElement:e,elementPositionKey:o})=>{const{left:n,top:s,width:a,height:l}=e[o],i=n+a,r=s+l;return t.filter(u=>{const{left:p,top:g,width:b}=u[o],y=p+b,k=g>=r,I=n>=p&&n=y,T=n<=p&&i>p;return k&&(I||E||T)||u.elementId===e.elementId})},ZV=({blockId:t})=>{const{getters:e,dispatch:o}=nt(),{saveBlockMinHeight:n}=Zg({blockId:t}),s=c(()=>e.siteBlocks),a=c(()=>e.siteElements),l=c(()=>s.value[t]),i=c(()=>{var g;return(g=l.value)!=null&&g.components?l.value.components.map(b=>({...a.value[b],elementId:b})):null}),r=c(()=>e["gui/isMobileMode"]),u=c(()=>r.value?se:ge);return{updatePositionsForElementsBelow:({elementId:g})=>{if(!i.value)return;const b={elementId:g,...a.value[g]},y=KV({blockElements:i.value,activeElement:b,elementPositionKey:u.value}),{position:k}=S3({elementId:g,blockId:t,isMobileMode:u.value===se}),I=k.height-b[u.value].height,E=YV({element:b,elementTopOffset:I,newElementPosition:k,layoutElements:y,elementPositionKey:u.value});o("mergeBulkElementsData",{elementsData:E});const T=l.value[u.value].minHeight+I;n({minHeight:T,saveToHistory:!1})}}},QV=({multiSelectedElements:t,elementPositionKey:e})=>{const o=Object.values(t).reduce((i,r)=>{const{top:u,height:p,left:g,width:b}=r[e],y=g+b,k=u+p;return{top:[...i.top,u],left:[...i.left,g],right:[...i.right,y],bottom:[...i.bottom,k]}},{top:[],left:[],right:[],bottom:[]}),n=Math.min(...o.left),s=Math.min(...o.top),a=Math.max(...o.right),l=Math.max(...o.bottom);return{left:n,top:s,width:a-n,height:l-s}},XV=({elementPosition:t,multiSelectPosition:e})=>{const{top:o,height:n,left:s,width:a}=t,l=o+n,i=s+a,{top:r,bottom:u,left:p,right:g}=e,b=o>=r&&o<=u,y=l>=r&&l<=u,k=o<=r&&l>=u,I=s>=p&&s<=g,E=i>=p&&i<=g,T=s<=p&&i>=g;return(b||y||k)&&(I||E||T)},JV=()=>{const{getters:t,dispatch:e,state:o}=nt(),n=c(()=>o.currentBlockId),s=c(()=>t["gui/isMobileMode"]),a=c(()=>s.value?se:ge),l=C({}),i=C(null),r=C(null),u=C({}),p=C(null),g=C({}),b=c(()=>Object.keys(g.value)),y=C(!1),k=C(!1),I=c(()=>b.value.length>$m&&!y.value),E=c(()=>p.value?document.querySelector(`[data-block-ref='${p.value}']`).getBoundingClientRect():{}),T=c(()=>E.value.top),P=c(()=>E.value.left),z=c(()=>{const{top:U,left:Y,width:F,height:W}=l.value,V=U-T.value,K=V+W,Z=Y-P.value,N=Z+F;return{top:V,bottom:K,left:Z,right:N}}),L=()=>{l.value={top:0,left:0,width:0,height:0},g.value={},p.value=null},D=({event:U,blockId:Y})=>{L(),i.value=U.pageX,r.value=U.pageY,l.value={top:U.pageY,left:U.pageX,width:0,height:0},k.value=!0,p.value=Y},$=({layoutElements:U,shouldForceUpdate:Y})=>{!y.value&&!Y||(g.value=Object.fromEntries(U.map(F=>{const W=b.value.includes(F.elementId);return!y.value&&W?[F.elementId,F]:XV({elementPosition:F[a.value],multiSelectPosition:z.value})?[F.elementId,F]:[]}).filter(([F])=>!!F)),u.value=QV({multiSelectedElements:g.value,elementPositionKey:a.value}))},A=({event:U,layoutElements:Y})=>{y.value=k.value,y.value&&(l.value={top:Math.min(r.value,U.pageY),left:Math.min(i.value,U.pageX),width:Math.abs(U.pageX-i.value),height:Math.abs(U.pageY-r.value)},$({shouldForceUpdate:!1,layoutElements:Y}))},M=()=>{b.value.length===$m&&e("selectCurrentElement",{elementId:b.value[0]}),k.value=!1,y.value=!1};return Rt([s,n],()=>{L()}),Rt(g,(U,Y)=>{const F=Object.keys(Y).length<=$m,W=Object.keys(U).length===0;if(F||!W)return;const V=Object.values(Y).map(K=>K.type).join(",");Et.logEvent({eventName:"website_builder.builder_multi_select.selected",eventProperties:{elements_selected:V}})}),{isMultiSelecting:y,isMultiSelectActive:I,multiSelectedBlockId:p,multiSelectedElements:g,multiSelectedElementsIds:b,startSelection:D,updateSelection:A,endSelection:M,resetMultiSelection:L,updateMultiSelectedElements:$,dragBoxStartXPosition:i,dragBoxStartYPosition:r,dragBoxPosition:l,multiSelectPosition:z,multiSelectAreaPosition:u}},tU=({elements:t,mobileElementsOrder:e,spacingY:o})=>e.reduce((n,s)=>{const a=t[s],l=a[se],i=e.indexOf(s),r=e[i-1],u=n.find(({elementId:E})=>E===r),p=u==null?void 0:u[se],g=p&&p.top+p.height,b=u?g+o:o,k=Ed/2-l.width/2,I={...a,[se]:{...l,top:b,left:k}};return[...n,I]},[]),eU=({selectedElementId:t,mobileElementsGroups:e,currentMobileElementsOrder:o,newMobileElementsOrder:n,multiSelectLength:s=0})=>{const a=s?s-1:0,l=n.indexOf(t){const{dispatch:e,getters:o}=nt(),n=c(()=>o.siteElements),s=c(()=>o.siteBlocks),a=c(()=>o["gui/isMobileMode"]),l=c(()=>s.value[t.blockId.value]),i=c(()=>{var z;return(z=l.value)!=null&&z.components?l.value.components.map(L=>({...n.value[L],elementId:L})):[]}),r=c(()=>Object.fromEntries(i.value.map(z=>[z.elementId,z]))),u=c(()=>Xb({elements:i.value,elementPositionKey:se})),p=c(()=>i.value.sort((z,L)=>z[se].top-L[se].top).map(z=>z.elementId)),g=c(()=>{const z=U7({elements:i.value});return j7({elementsColumnGroups:z,blockElements:r.value})}),b=c(()=>g.value.flatMap(z=>z.elements)),y=c(()=>l.value&&!!l.value[C1]),k=c(()=>GR({array1:p.value,array2:b.value})),I=c(()=>!y.value&&a.value&&l.value.type===Us&&l.value.components.length>=dB),E=({selectedElementId:z,multiSelectLength:L})=>{eU({selectedElementId:z,currentMobileElementsOrder:p.value,newMobileElementsOrder:b.value,mobileElementsGroups:u.value,multiSelectLength:L}).forEach(({elementId:$,position:A})=>{e("mergeElementData",{elementId:$,elementData:{[se]:{...A}}})})},T=({selectedElementsIds:z})=>{const L=z.every(Y=>r.value[Y]);if(!y.value||!L)return;const D=z.length>1,$=W7({elementsIds:z,blockElements:r.value}),A=p.value.findIndex(Y=>Y===$),M=b.value.findIndex(Y=>Y===$);A!==M&&E(D?{selectedElementId:z[0],multiSelectLength:z.length}:{selectedElementId:$})},P=({isMobileAutoPositioningEnabled:z})=>{if(e("updateBlockData",{blockId:t.blockId.value,blockData:{[C1]:z?!0:null},merge:!0}),!z)return;const L=l.value.snapRowGap||lr,D=tU({elements:r.value,mobileElementsOrder:b.value,spacingY:L}),$=D[D.length-1],M=$[se].top+$[se].height+L;D.forEach(({elementId:U,mobile:Y})=>{e("mergeElementData",{elementId:U,elementData:{[se]:{...Y}}})}),e("updateBlockData",{blockId:t.blockId.value,blockData:{[se]:{minHeight:M}},merge:!0}),e("undoRedo/createSnapshot")};return Rt([i,t.blockId],([z,L],[D,$])=>{if(!(!(z.length!==D.length)||L!==$||!i.value.length)){if(a.value)P({isMobileAutoPositioningEnabled:!1});else if(z.length>D.length){const U=q7({oldElements:D,newElements:z});T({selectedElementsIds:[U]})}}}),Rt(k,z=>{a.value&&y.value&&!z&&P({isMobileAutoPositioningEnabled:!1})}),{updateSectionElementsMobileOrder:T,isMobileAutoPositioningEnabled:y,isMobileElementsOrderTheSameAsDesktop:k,isMobileAutoPositioningToggleVisible:I,updateMobileAutoPositioning:P}},L_=t=>iB[t]||sB,ss=(t,e)=>e.reduce((o,n)=>Math.abs(n-t)<=Math.abs(o-t)?n:o,null),or=({elementId:t,blockId:e,dispatch:o,isMobileMode:n})=>{const s=n?ei:ar,a=n?se:ge,{position:l,blockWidth:i}=S3({elementId:t,blockId:e,isMobileMode:n});s===Math.round(i)&&(Se({category:"LAYOUT_CALCULATED_POSITION",message:"Update element position",data:{calculatedPosition:l,elementId:t,elementPositionFromDom:l,method:"updateElementPositionFromDOM"},level:"debug",type:"debug"}),o("mergeElementData",{elementId:t,elementData:{[a]:l}}))},O_=({multiSelectAreaPosition:t,draggedElementsSnapPosition:e,shouldFitToLayoutYBounds:o,multiSelectedElements:n,elementPositionKey:s,blockWidth:a})=>{const{top:l,left:i}=t,{top:r,left:u}=o?Os(e):e,p=l-r,g=i-u;return Object.fromEntries(Object.entries(n).map(([,b])=>{const{top:y,left:k,height:I,width:E}=b[s],T=$n({height:I,width:E,left:k-g,top:y-p},a);return[b.elementId,T]}))},oU=({elementsIds:t,oldBlockId:e,newBlockId:o,dispatch:n})=>{t.forEach(s=>{n("moveElementBetweenBlocks",{elementId:s,oldBlockId:e,newBlockId:o})})},nU=({elementsPositions:t,draggedElementPosition:e,elementPositionKey:o,multiselectAreaPosition:n})=>{const{top:s,left:a}=n;return Object.fromEntries(Object.entries(t).map(([l,i])=>{const r=Math.abs(e.top-i.top),u=Math.abs(e.left-i.left),{width:p,height:g}=Os(i);return[l,{[o]:{top:s+r,left:a+u,width:p,height:g}}]}))},Ef=C(!1),Si=C(),Ds=C(),yI=(t,e)=>{const{getters:o,dispatch:n,state:s}=nt(),a=c(()=>s.fonts.hasGoogleFontsLoaded),l=c(()=>t.components),i=c(()=>o["gui/isMobileMode"]),r=c(()=>o.currentElementId),u=c(()=>o.currentElementBlockId),p=c(()=>o.addElementData),g=c(()=>t.data),b=c(()=>t.blockId),y=C(),k=C(null),I=C(0),{hoveredBlockId:E,hoveredBlock:T}=kl(),P=c(()=>{var It;return(It=T.value)==null?void 0:It.type}),{updateSectionElementsMobileOrder:z}=fI({blockId:b}),{layoutElements:L,blockElements:D,layoutCSSVars:$,buildResponsiveGrid:A,isMobileLegacy:M}=Vc({blockData:g,siteElements:l,shouldBuildResponsive:!1}),{updatePositionsForElementsBelow:U}=ZV({blockId:b.value}),{isElementVisibleOnScreen:Y}=bI(),{addLayoutElement:F}=za(),{startDragging:W,hasMouseMoved:V,dragDeltaXPosition:K,dragDeltaYPosition:Z,isDragging:N}=ky(),{isMultiSelecting:X,isMultiSelectActive:et,multiSelectedElements:pt,multiSelectedElementsIds:st,multiSelectedBlockId:J,startSelection:it,updateSelection:at,endSelection:ot,resetMultiSelection:ft,updateMultiSelectedElements:tt,dragBoxPosition:gt,multiSelectAreaPosition:Q}=JV(),{saveBlockMinHeight:bt,updateSectionMinHeight:wt}=Zg(t),yt=C(),At=C(!1),mt=C(!1),Ct=c(()=>!!Si.value),xt=c(()=>et.value?J.value:u.value),Ht=c(()=>Ds.value??Si.value),Gt=c(()=>L.value.find(({elementId:It})=>It===Ht.value)),Lt=c(()=>i.value?se:ge),Tt=c(()=>At.value?ey({layoutElements:L.value,activeElementId:Ht.value,elementPositionKey:Lt.value}):[]),Vt=c(()=>Tt.value.map(({elementId:It})=>It)),ae=c(()=>{var It;return((It=Tt.value.sort((Mt,Qt)=>{const{top:te,height:Jt}=Mt[Lt.value],{top:we,height:Re}=Qt[Lt.value],Ke=te+Jt||0;return(we+Re||0)-Ke})[0])==null?void 0:It.elementId)||null}),ht=c(()=>At.value?L.value.filter(It=>{const Mt=It.elementId!==Ht.value,{top:Qt,height:te}=Gt.value[Lt.value],{top:Jt,height:we}=It[Lt.value],Re=Qt+te,Ke=Jt+we,Ze=Re>Ke;return Mt&&Ze}):[]),$t=c(()=>ht.value.sort((It,Mt)=>{const{top:Qt,height:te}=It[Lt.value],{top:Jt,height:we}=Mt[Lt.value],Re=Qt+te||0;return(Jt+we||0)-Re})[0]||{}),kt=c(()=>{var It;return(It=$t.value)==null?void 0:It.elementId}),Pt=c(()=>{var It;return((It=$t.value)==null?void 0:It[Lt.value])||{}}),Dt=c(()=>{const{top:It,height:Mt}=Pt.value;return It+Mt}),Ot=c(()=>g.value.snapRowHeight||Yf),Wt=c(()=>g.value.snapRowGap||lr),re=c(()=>Math.abs(K.value)!==0||Math.abs(Z.value)!==0),pe=(It,Mt)=>c(()=>re.value&&(It in g.value?g.value[It]:Mt)),he=pe("shouldSnapToElements",Kf),Oe=pe("shouldSnapToGuides",Zf),Ce=c(()=>{if(et.value)return Q.value;const It=L.value.find(({elementId:Mt})=>Mt===Ht.value);return(It==null?void 0:It[Lt.value])||{}}),Ft=c(()=>he.value?L.value.filter(({elementId:It})=>It!==Ht.value).map(It=>{const{left:Mt,top:Qt,width:te,height:Jt}=It[Lt.value];return{...It[Lt.value],elementId:It.elementId,right:Mt+te,bottom:Qt+Jt,centerX:Math.round(Mt+te/2),centerY:Math.round(Qt+Jt/2)}}):[]),de=c(()=>Ft.value.filter(({elementId:It})=>Y(It))),Pe=c(()=>i.value?Ns:ar),St=c(()=>g.value.desktop.minHeight),xe=c(()=>g.value.mobile.minHeight),qe=c(()=>t.blockId===Wi.value&&k.value?k.value:i.value?xe.value:St.value),Zt=c(()=>Pe.value/2),ro=c(()=>i.value?rB:lB),Eo=c(()=>Math.round(qe.value/(Ot.value+Wt.value))),$o=c(()=>{const It=(ro.value-1)*Fb;return(Pe.value-It)/ro.value}),sn=c(()=>[...Array(ro.value)].map((It,Mt)=>Mt*($o.value+Fb))),ns=c(()=>sn.value.map(It=>It+$o.value)),Al=c(()=>[...Array(Eo.value)].map((It,Mt)=>Math.floor(Mt*(Ot.value+Wt.value)))),Xr=c(()=>[...Array(Eo.value)].map((It,Mt)=>Math.floor(Mt*(Ot.value+Wt.value)+Ot.value))),Ts=c(()=>["left","bottom-left","top-left"].includes(yt.value)),Dl=c(()=>["right","bottom-right","top-right"].includes(yt.value)),aa=c(()=>["top","top-left","top-right"].includes(yt.value)),zl=c(()=>["top-left","top-right"].includes(yt.value)),_e=c(()=>["bottom","bottom-left","bottom-right"].includes(yt.value)),Ye=c(()=>["bottom-left","bottom-right"].includes(yt.value)),Vi=c(()=>["bottom-left","bottom-right","top-left","top-right"].includes(yt.value)),Be=c(()=>["left","right"].includes(yt.value)),Zo=c(()=>["top","bottom"].includes(yt.value)),Bn=c(()=>{const{width:It,height:Mt,left:Qt,top:te}=Ce.value,Jt=At.value?Qt:Qt+K.value,we=te+Z.value;if(At.value){if(we<=Dt.value&&te>=Dt.value)return $n({height:Mt,width:It,left:Jt,top:Dt.value},Pe.value);if(we<=0)return $n({height:Mt,width:It,left:Jt,top:0},Pe.value)}return $n({height:Mt,width:It,left:Jt,top:we},Pe.value)}),Jr=c(()=>Bn.value.top===Dt.value),Tm=c(()=>!At.value||!Jr.value?null:kt.value),Cs=c(()=>P.value==="BlockLayout"&&xt.value&&E.value&&xt.value!==E.value&&!At.value?Bn.value.top<0?Math.abs(Bn.value.top)>Bn.value.height:Bn.value.top>St.value:!1),lu=c(()=>{const It=sn.value.map(Jt=>({snapsTo:["left"],location:Jt,type:Ro.COLUMN})),Mt=ns.value.map(Jt=>({snapsTo:["right"],location:Jt,type:Ro.COLUMN})),Qt=[...It,...Mt];return[...new Set(Qt.map(({location:Jt})=>Jt))].map(Jt=>Qt.find(we=>we.location===Jt))}),ru=c(()=>{const It=de.value.reduce((te,{top:Jt,centerX:we,bottom:Re})=>[...te,{location:we,snapsTo:["center"],type:Ro.ELEMENT_CENTER,top:Jt,bottom:Re}],[]),Mt=[{snapsTo:["left","right","center"],location:Zt.value,type:Ro.BLOCK_CENTER},...It];return[...new Set(Mt.map(({location:te})=>te))].map(te=>Mt.find(Jt=>Jt.location===te))}),la=c(()=>he.value&&Oe.value?[...lu.value,...ru.value]:he.value?[...ru.value]:Oe.value?[...lu.value]:[]),ee=c(()=>{const It=Al.value.map(Jt=>({snapsTo:["top"],location:Jt,type:Ro.ROW})),Mt=Xr.value.map(Jt=>({snapsTo:["bottom"],location:Jt,type:Ro.ROW})),Qt=[...It,...Mt];return[...new Set(Qt.map(({location:Jt})=>Jt))].map(Jt=>Qt.find(we=>we.location===Jt))}),fe=c(()=>{const Mt=[...de.value.reduce((te,{top:Jt,centerY:we,bottom:Re,left:Ke,right:Ze})=>[...te,{location:Jt,type:Ro.ELEMENT_EDGE,snapsTo:["left, right"],left:Ke,right:Ze},{location:we,type:Ro.ELEMENT_CENTER,snapsTo:["left, right"],left:Ke,right:Ze},{location:Re,type:Ro.ELEMENT_EDGE,snapsTo:["left, right"],left:Ke,right:Ze,bottom:Re}],[])];return[...new Set(Mt.map(({location:te})=>te))].map(te=>Mt.find(Jt=>Jt.location===te))}),Ne=c(()=>he.value&&Oe.value?[...fe.value,...ee.value]:he.value?[...fe.value]:Oe.value?[...ee.value]:[]),uo=c(()=>la.value.filter(It=>It.snapsTo.includes("left")).map(({location:It})=>It)),is=c(()=>la.value.filter(It=>It.snapsTo.includes("center")).map(({location:It})=>It)),ra=c(()=>la.value.filter(It=>It.snapsTo.includes("right")).map(({location:It})=>It)),du=c(()=>{const{left:It,width:Mt}=Bn.value,Qt=ss(It,uo.value),te=Math.abs(It-Qt),Jt=ss(It+Mt,ra.value),we=Math.abs(It+Mt-Jt),Re=ss(Math.round(It+Mt/2),is.value),Ke=Math.abs(Math.round(It+Mt/2)-Re),Ze=Math.min(te,Ke,we);return Ze>Hm?null:Ze===te?Qt:Ze===we?Jt-Mt:Ze===Ke?Re-Math.round(Mt/2):null}),td=c(()=>Ne.value.map(({location:It})=>It)),Nv=c(()=>fe.value.map(({location:It})=>It)),ed=c(()=>{const{height:It,top:Mt}=Bn.value,Qt=ss(Mt,td.value),te=Math.abs(Mt-Qt),Jt=ss(Math.round(Mt+It/2),Nv.value),we=Math.abs(Math.round(Mt+It/2)-Jt),Re=ss(Mt+It,td.value),Ke=Math.abs(Mt+It-Re),Ze=Math.min(te,we,Ke);return Ze>Nm?null:Ze===te?Qt:Ze===we?Jt-Math.round(It/2):Ze===Ke?Re-It:null}),Ui=c(()=>{const{height:It,width:Mt,left:Qt,top:te}=Bn.value;return $n({left:du.value??Qt,top:ed.value??te,width:Mt,height:It},Pe.value)}),da=c(()=>{const{top:It,left:Mt,width:Qt,height:te}=Ce.value,Jt=()=>{const Re=Ts.value?Mt+Qt:Pe.value-Mt,Ke=Ts.value?Math.round(Qt-K.value):Math.round(Qt+K.value),Ze=Math.max(Math.min(Ke,Re),L_(Gt.value.type)),$l=Ts.value?Mt+(Qt-Ze):Mt;return $n({left:$l,width:Ze,height:te,top:It},Pe.value)},we=()=>{const Re=aa.value?It+te:oB,Ke=aa.value?Math.ceil(te-Z.value):Math.ceil(te+Z.value),Ze=Math.max(Math.min(Ke,Re),x1),$l=aa.value?It+(te-Ze):It;return $n({left:Mt,width:Qt,height:Ze,top:$l},Pe.value)};if(Vi.value){const Re=we(),Ke=Jt();return{top:Re.top,left:Ke.left,width:Ke.width,height:Re.height}}return Zo.value?we():Be.value?Jt():{top:It,left:Mt,width:Qt,height:te}}),Gv=c(()=>[...sn.value,Zt.value]),Fv=c(()=>[...ns.value,Zt.value]),Vv=c(()=>Ne.value.map(({location:It})=>It)),Uv=c(()=>{const{left:It,width:Mt}=da.value,Qt=ss(It,Gv.value),te=Math.round(It-Qt),Jt=ss(It+Mt,Fv.value),we=Math.round(It+Mt-Jt);return Math.abs(te){const{height:It,top:Mt}=da.value,Qt=ss(Mt,Vv.value),te=Mt-Qt,Jt=ss(Mt+It,Vv.value),we=Mt+It-Jt;return Math.abs(te){const Mt=Ce.value.width/Ce.value.height,Qt=Ts.value||Dl.value,te=Zo.value?Mt*It.height:It.width,Jt=Qt?It.width/Mt:It.height,we=Math.max(te,L_(Gt.value.type)),Re=Math.max(Jt,x1),Ke=It.top===0,Ze=zl.value&&!Ke?It.top+(It.height-Re):It.top;return{left:It.left,top:Ze,width:we,height:Re}},qE=c(()=>{const{left:It,width:Mt,height:Qt,top:te}=da.value,Jt=Uv.value.left??It,we=Uv.value.width||Mt,Re=jv.value.top||te,Ke=jv.value.height||Qt,Ze={left:Jt,top:Re,width:we,height:Ke};return zl.value||Ye.value?$n(WE(Ze),Pe.value):$n(Ze,Pe.value)}),Cm=c(()=>!et.value||!Ce.value?{}:O_({multiSelectAreaPosition:Q.value,draggedElementsSnapPosition:Ui.value,shouldFitToLayoutYBounds:!1,multiSelectedElements:pt.value,elementPositionKey:Lt.value,blockWidth:Pe.value})),Pm=c(()=>Cs.value||Oe.value||he.value),fn=c(()=>et.value?Si.value?Ui.value:Bn.value:Si.value?Pm.value?Ui.value:Bn.value:Ds.value?Pm.value?qE.value:da.value:{}),YE=c(()=>{const It=i.value?Li:0;if(et.value)return{left:fn.value.left+It,top:fn.value.top,width:fn.value.width,height:fn.value.height};const{top:Mt,left:Qt,width:te,height:Jt}=gt.value;return{left:Qt,top:Mt,width:te,height:Jt}}),cu=c(()=>{if(!At.value)return{};const It=Ce.value.top-Os(Ui.value).top;return Kp({topOffset:It,elementPositionKey:Lt.value,lowerElementsRelativeToActive:Tt.value})}),Bm=c(()=>{const It=ae.value?cu.value[ae.value]:fn.value,{top:Mt,height:Qt}=It;return Mt+Qt}),Wv=c(()=>{if(!Object.keys(Cm.value).length&&!Object.keys(cu.value).length)return{};const It=Object.keys(Cm.value).length?Cm.value:{[Ht.value]:fn.value,...cu.value};return Object.fromEntries(Object.entries(It).map(([Mt,Qt])=>{const te={"--element-top":`${Qt.top}px`,"--element-left":`${Qt.left}px`,"--element-width":`${Qt.width}px`,"--element-height":`${Qt.height}px`};return[Mt,te]}))}),KE=c(()=>{if(!Gt.value||Object.keys(Wv.value).length)return null;const It=o1.includes(Gt.value.type);return{"--element-top":`${fn.value.top}px`,"--element-left":`${fn.value.left}px`,"--element-width":`${fn.value.width}px`,"--element-height":It?`${fn.value.height}px`:"auto"}}),ZE=c(()=>{if(!Ht.value)return null;if(Si.value){const{width:It,left:Mt}=fn.value,Qt=Math.round(Mt+It/2),te=Mt+It,Jt=[];return uo.value.includes(Mt)&&Jt.push(Mt),is.value.includes(Qt)&&Jt.push(Qt),ra.value.includes(te)&&Jt.push(te),la.value.filter(({location:we})=>Jt.includes(we))}if(Ds.value){const{width:It,left:Mt}=fn.value,Qt=Math.round(Mt+It),te=[];return Gv.value.includes(Mt)&&te.push(Mt),Fv.value.includes(Qt)&&te.push(Qt),la.value.filter(({location:Jt})=>te.includes(Jt))}return null}),QE=c(()=>{if(!Ht.value)return null;if(Si.value){const{height:It,top:Mt}=fn.value,Qt=Math.round(Mt+It/2),te=Mt+It,Jt=[Mt,Qt,te];return Ne.value.filter(({location:we})=>Jt.includes(we))}if(Ds.value){const{height:It,top:Mt}=fn.value,Qt=Mt+It,te=[Mt,Qt];return Ne.value.filter(({location:Jt})=>te.includes(Jt))}return null}),XE=()=>{var we;if(et.value){const Re=O_({multiSelectAreaPosition:Q.value,draggedElementsSnapPosition:Ui.value,shouldFitToLayoutYBounds:!Cs.value,multiSelectedElements:pt.value,elementPositionKey:Lt.value,blockWidth:Pe.value});if(Cs.value){const Ze=Sr({elementId:`${xt.value}-drag-box`,blockId:E.value}),$l=Os(Ze);oU({elementsIds:st.value,oldBlockId:xt.value,newBlockId:E.value,dispatch:n});const ax=nU({elementsPositions:Re,draggedElementPosition:Ui.value,elementPositionKey:Lt.value,multiselectAreaPosition:$l});n("mergeBulkElementsData",{elementsData:ax});return}const Ke=Zp({elementsPositions:Re,elementPositionKey:Lt.value});n("mergeBulkElementsData",{elementsData:Ke});return}if(Ht.value===xb)return;if(At.value){const Re=Ce.value.top-Os(Ui.value).top,Ke=Kp({topOffset:Re,elementPositionKey:Lt.value,lowerElementsRelativeToActive:Tt.value}),Ze=Zp({elementsPositions:{[Ht.value]:fn.value,...Ke},elementPositionKey:Lt.value});n("mergeBulkElementsData",{elementsData:Ze});return}const It=Cs.value?Sr({elementId:Ht.value,blockId:E.value,leftOffset:i.value?Li:0}):fn.value,{top:Mt,left:Qt,width:te,height:Jt}=Os(It);Cs.value&&(n("moveElementBetweenBlocks",{elementId:Ht.value,oldBlockId:xt.value,newBlockId:E.value}),n("unselectCurrentElement")),Se({category:"LAYOUT_CALCULATED_POSITION",message:"Update element position",data:{isElementMovedToOtherBlock:Cs.value,availableLayoutElements:(we=L.value)==null?void 0:we.map(({elementId:Re})=>Re),isMultiSelectActive:et.value,shouldSnap:Pm.value,blockWidth:Pe.value,elementId:Ht.value,draggedElementId:Si.value,resizedElementId:Ds.value,draggedElementPosition:Bn.value,initialElementPosition:{...Ce.value},position:It,method:"updateActiveElementData"},level:"debug",type:"debug"}),n("mergeElementData",{elementId:Ht.value,elementData:{[Lt.value]:{top:Mt,left:Qt,width:te,height:Jt}}})},JE=async()=>{XE(),await $e(),i.value||z({selectedElementsIds:et.value?st.value:[Si.value]}),Si.value=null,n("undoRedo/createSnapshot"),e("set-edit-control-visibility",!0),At.value&&(At.value=!1,I.value=0,k.value=null,mt.value=!1,Fs.value&&(bt({minHeight:Fs.value,saveToHistory:!0}),Wi.value=null)),await $e(),tt({shouldForceUpdate:!0,layoutElements:L.value}),wt()},tx=({elementId:It,shouldMoveElementsBellow:Mt=!1})=>{const Qt=It===xb;et.value&&!Qt&&ft(),o.isEditingTextBoxElement&&l.value[It].type===Po||(Si.value=It,At.value=Mt,Mt&&(mt.value=qe.value===Bm.value),e("set-edit-control-visibility",!1),W({onDragEnd:JE}))},ex=()=>{Ht.value&&(or({dispatch:n,elementId:Ht.value,blockId:t.blockId,isMobileMode:i.value}),wt(),Ds.value=null,yt.value=null,e("set-edit-control-visibility",!0),n("undoRedo/createSnapshot"))},ox=(It,Mt)=>{Ds.value=It,yt.value=Mt,e("set-edit-control-visibility",!1),W({onDragEnd:ex})},nx=async It=>{const{elementId:Mt,elementData:Qt,width:te,height:Jt}=p.value;if(!Qt)return;const we={newElementRawLeft:It.clientX,newElementRawTop:It.clientY,newElementRawWidth:te,newElementRawHeight:Jt};await F({blockElements:D.value,blockId:t.blockId,blockToAddRef:It.currentTarget,elementId:Mt,newElementData:Qt,newElementRawPosition:we,newElementRelativePosition:Wp.EXACT}),n("updateAddElementData",{}),n("selectCurrentElement",{elementId:Mt})},ix=It=>{const Mt=o.siteElements[It],Qt=!!Mt;if(!Ht.value&&Qt){if(Mt.type===Po&&r.value===It&&U({elementId:It}),Mt.type===Po&&!a.value)return;or({dispatch:n,elementId:It,blockId:t.blockId,isMobileMode:i.value})}},sx=It=>o1.includes(It)?nB:KT.includes(It)?["left","right"]:[];return Rt(cu,()=>{if(!At.value)return;!I.value&&!mt.value&&(I.value=qe.value-Bm.value),mt.value&&(I.value=0);const It=Bm.value+I.value;It>=qe.value&&!Wi.value&&(Wi.value=xt.value),Wi.value&&(Fs.value=It,(!k.value||k.valueo.currentBlock),a=c(()=>s.value.snapRowHeight||Yf),l=c(()=>s.value.snapRowGap||lr),i=c(()=>"shouldSnapToElements"in s.value?s.value.shouldSnapToElements:Kf),r=c(()=>"shouldSnapToGuides"in s.value?s.value.shouldSnapToGuides:Zf),u=c(()=>!!s.value.shouldKeepGridVisible);Nt(()=>{Ef.value=!0}),mn(()=>{Ef.value=!1});const p=(g,b)=>{if(QT[g]===b){const{[g]:y,...k}=s.value;n("updateBlockData",{blockId:e.currentBlockId,blockData:k,merge:!1});return}n("updateBlockData",{blockId:e.currentBlockId,blockData:{[g]:b},merge:!0})};return(g,b)=>{const y=ct("qa");return d(),v("div",iU,[h(eo,{id:"toggle-snapping","qa-selector":"sectionsettings-snaptoguides-toggle","model-value":r.value,label:g.$t("builder.editBlockTabLayout.toggleGuideSnappingLabel"),message:g.$t("builder.editBlockTabLayout.toggleGuideSnappingDescription"),class:"layout-tab__snap-to-guides","onUpdate:modelValue":b[0]||(b[0]=k=>p("shouldSnapToGuides",k))},null,8,["model-value","label","message"]),h(eo,{id:"toggle-snapping-elements","model-value":i.value,label:g.$t("builder.editBlockTabLayout.toggleSnappingToElements"),"onUpdate:modelValue":b[1]||(b[1]=k=>p("shouldSnapToElements",k))},null,8,["model-value","label"]),r.value?(d(),v("div",sU,[h(Xt,null,{default:_(()=>[j(w(g.$t("builder.editBlockTabLayout.controlRangeRowHeight")),1)]),_:1}),O(h(Jo,{min:8,max:40,step:"1","has-number-input":"","model-value":a.value,"onUpdate:modelValue":b[2]||(b[2]=k=>p("snapRowHeight",k))},null,8,["model-value"]),[[y,"section-settings-row-height-range"]])])):B("",!0),r.value?(d(),v("div",aU,[h(Xt,null,{default:_(()=>[j(w(g.$t("builder.editBlockTabLayout.controlRangeRowGap")),1)]),_:1}),O(h(Jo,{min:8,max:40,step:"1","has-number-input":"","model-value":l.value,"onUpdate:modelValue":b[3]||(b[3]=k=>p("snapRowGap",k))},null,8,["model-value"]),[[y,"section-settings-row-gap-range"]])])):B("",!0),h(ye,{class:"layout-tab__separator"}),h(eo,{id:"toggle-keep-grid-visible","model-value":u.value,label:g.$t("builder.editBlockTabLayout.keepGridVisible"),"onUpdate:modelValue":b[4]||(b[4]=k=>p("shouldKeepGridVisible",k))},null,8,["model-value","label"])])}}},rU=H(lU,[["__scopeId","data-v-d248b269"]]),dU=q({components:{ZyroPopupCard:zo,EditBlockTabBackground:qc,EditBlockTabAnchor:QM,EditBlockLayoutTabLayout:rU},props:{startTabId:{type:String,default:null}},emits:["close"],setup(t){const{t:e}=_t(),o=[{id:"background",title:e("common.background"),component:"EditBlockTabBackground"},{id:"layout",title:e("common.layout"),component:"EditBlockLayoutTabLayout"},{id:"anchor",title:e("common.anchor"),component:"EditBlockTabAnchor"}],n=o.find(a=>a.id===t.startTabId)??o[0],s=C(n);return{tabs:o,currentTab:s}}});function cU(t,e,o,n,s,a){const l=G("ZyroPopupCard");return d(),S(l,{type:"editor",title:t.$t("builder.sectionSettings.title"),tabs:t.tabs,"current-tab":t.currentTab,"onUpdate:currentTab":e[0]||(e[0]=i=>t.currentTab=i),onClose:e[1]||(e[1]=i=>t.$emit("close"))},{default:_(()=>[(d(),S(yo(t.currentTab.component)))]),_:1},8,["title","tabs","current-tab"])}const uU=H(dU,[["render",cU]]),pU=t=>(ke("data-v-d3f40473"),t=t(),Ie(),t),gU=["onMousedown","onTouchstart"],mU=pU(()=>m("div",{class:"resize-dot__visual-trigger"},null,-1)),hU=[mU],bU={__name:"ResizeDots",props:{elementWidth:{type:Number,required:!0},elementHeight:{type:Number,required:!0},resizeDirections:{type:Array,default:()=>[]}},emits:["start-resizing"],setup(t,{emit:e}){const o=t,n=e,{handleTouchEvent:s}=Kg(),a=c(()=>o.resizeDirections.length===2&&o.resizeDirections.includes("left")&&o.resizeDirections.includes("right")),l=c(()=>!a.value&&o.elementHeight<=T1),i=c(()=>o.elementWidth<=T1),r=c(()=>l.value&&i.value),u=(p,g)=>{p.preventDefault(),s(p),n("start-resizing",g)};return(p,g)=>(d(),v("div",Fe({class:["resize-dots",{"resize-dots--horizontal-hidden":l.value,"resize-dots--vertical-hidden":i.value,"resize-dots--hidden":r.value,"resize-dots--only-horizontal":a.value}],[f(ko)||""]:f(t4)}),[(d(!0),v(dt,null,zt(t.resizeDirections,b=>(d(),v("div",{key:b,class:rt(["resize-dot",[`resize-dot--${b}`]]),onMousedown:Yt(y=>p.$emit("start-resizing",b),["left","stop"]),onTouchstart:Yt(y=>u(y,b),["stop"])},hU,42,gU))),128))],16))}},fU=H(bU,[["__scopeId","data-v-d3f40473"]]),yU=q({name:"LayoutElementWrapper",props:{elementData:{type:Object,required:!0},isForcedOnTop:{type:Boolean,default:!1},isMobileLegacy:{type:Boolean,default:!1},isMobileView:{type:Boolean,default:!1}},computed:{settings(){return this.elementData.settings},styles(){return this.settings.styles},innerBackgroundValue(){const{innerBackground:t}=this.elementData;if(!t)return{};const e=t[t.current];return t.current!=="image"?{"--gridItemInnerBackground":e}:{"--gridItemInnerBackground":`url(${e})`,"--gridItemInnerBackgroundOverlayOpacity":"overlay-opacity"in t?t["overlay-opacity"]:null}},isHiddenDesktop(){return this.elementData.desktop.isHidden},isHiddenMobile(){return this.elementData.mobile.isHidden},computedStyles(){return{...vi(this.styles),...this.innerBackgroundValue,...this.isHiddenDesktop&&!this.isMobileView&&{"--hidden-element-z-index":0},...this.isHiddenMobile&&this.isMobileView&&{"--m-hidden-element-z-index":0},...this.isForcedOnTop&&{"--z-index":aC}}}}});function vU(t,e,o,n,s,a){return d(),v("div",{class:rt(["layout-element",{"layout-element--legacy":t.isMobileLegacy,"layout-element--layout":!t.isMobileLegacy}]),style:ne(t.computedStyles)},[vt(t.$slots,"default")],6)}const _U=H(yU,[["render",vU]]),Th=C(null),sm=()=>{const t=()=>{Th.value=null},e=o=>{Th.value=o};return{croppedImageId:c(()=>Th.value),exitCropMode:t,enterCropMode:e}},wU=C(!1),Ky=()=>({showGalleryManager:wU}),am=Wo(en.AI_WRITER,()=>{const t=C(!1),e=C(!1),{t:o}=_t(),{notify:n}=Le();return{getAiGeneratedText:async({userPrompt:l})=>{t.value=!0;try{const{data:i}=await iR({prompt:l});return i}catch(i){return i&&i.error===429?(e.value=!0,n({message:o("builder.AITextGeneratorPopupDailyLimitReachedDisclaimer")}),{}):(n({message:o("builder.AITextGenerationFailed")}),jt(i),{})}finally{t.value=!1}},isTextBeingGenerated:t,isAiTextGeneratorDailyLimitReached:e,setIsTextBeingGenerated:l=>{t.value=l}}}),$u=C(!1),Lu=C(""),Ps=C(""),Ou=C(""),Ch=C(!1),Zy=t=>{const{dispatch:e,getters:o}=nt(),n=am(),{t:s}=_t(),{notify:a}=Le(),{updateElementHeightOnDevices:l}=Gi(),{isTextBeingGenerated:i}=ai(n),r=c(()=>o.currentElementId),u=c(()=>o.currentElement),p=c(()=>o.isEditingTextBoxElement),g=c(()=>{const P=Vy(Lu.value);return P.length?P[P.length-1]:""}),b=c(()=>{const P=g.value?`style="color: ${g.value}"`:"";return`<${E1} ${P} class="${Jd}"
>${Ps.value}${E1}>`}),y=({pushToHistory:P=!1})=>{e("mergeElementData",{elementId:t.elementId,elementData:{content:`${Lu.value}${b.value}`}}),l({elementId:t.elementId}),P&&e("undoRedo/createSnapshot"),setTimeout(()=>{const z=document.querySelector(`[${_c}="${t.elementId}"]`);z&&z.scrollIntoView({block:"end",behavior:"smooth"})})},k=async({isTryingAgain:P})=>{Ch.value=!0,$u.value=!1,Ps.value="",P||(Lu.value=u.value.content);const{text:z}=await n.getAiGeneratedText({userPrompt:Ou.value});if(!(!z||t.elementId!==r.value)){if(z===d3){a({message:s("builder.AITextGenerationDescriptionNotClear")}),$u.value=!0;return}Ps.value=z,y({pushToHistory:!1})}},I=()=>{e("mergeElementData",{elementId:t.elementId,elementData:{content:Lu.value}}),Ps.value=""},E=()=>{y({pushToHistory:!0}),Ps.value=""},T=P=>{$u.value=P};return Rt(r,P=>{t&&P!==t.elementId&&(i.value&&(a({message:s("builder.AITextGenerationStopped")}),n.setIsTextBeingGenerated(!1)),Ps.value="",Ou.value="",Ch.value=!1)}),Rt(p,()=>{Ps.value.length&&p.value&&(Ps.value="",Ou.value="")}),{userPrompt:Ou,aiGeneratedText:Ps,isAiTextGeneratorPopupVisible:$u,generateAiText:k,discardAiGeneratedText:I,keepAiGeneratedText:E,isPromptInputTouched:Ch,setIsAiTextGeneratorPopupVisible:T}},lm=({selectedElementId:t}={})=>{const{getters:e,dispatch:o}=nt(),n=C(t),s=c(()=>e.siteBlocks),a=c(()=>Vg({elementId:n.value,siteBlocks:s.value})),l=c(()=>e.siteBlocks[a.value]),i=c(()=>e.siteElements),r=c(()=>e["gui/isMobileMode"]),u=c(()=>r.value?se:ge),p=c(()=>u.value===ge),g=c(()=>l.value.components.map(W=>{const V=i.value[W];return ji(V,{elementId:W,desktop:{bottom:V.desktop.top+V.desktop.height},mobile:{bottom:V.mobile.top+V.mobile.height}})})),b=c(()=>g.value.find(W=>W.elementId===n.value)),y=c(()=>Xb({elements:g.value,elementPositionKey:ge})),k=c(()=>Xb({elements:g.value,elementPositionKey:se})),I=c(()=>p.value?y.value:k.value),E=c(()=>o2({elementGroups:y.value,elementId:n.value})),T=c(()=>o2({elementGroups:k.value,elementId:n.value})),P=c(()=>p.value?E.value:T.value),z=c(()=>y.value[E.value]),L=c(()=>k.value[T.value]),D=c(()=>p.value?z.value:L.value),$=({elementPositions:W,elementPositionKey:V})=>W.forEach(({elementId:K,position:Z})=>o("mergeElementData",{elementId:K,elementData:{[V]:{...Z}}})),A=({higherGroup:W,lowerGroup:V})=>{const K=I3({higherGroup:W,lowerGroup:V,elementPositionKey:u.value});$({elementPositions:K,elementPositionKey:u.value}),o("undoRedo/createSnapshot")},M=({elementPositionKey:W,selectedElementGroup:V})=>{const{topMargin:K,bottomMargin:Z}=G7({elementToDeleteGroup:V,elementToDelete:b.value,elementPositionKey:W}),N=Xm({elements:V.elements.filter(pt=>pt.elementId!==n.value),shiftMargin:-K,elementPositionKey:W}),X=K+Z,et=Xm({elements:n2({elements:g.value,verticalTreshold:b.value[W].bottom,elementPositionKey:W}),shiftMargin:-X,elementPositionKey:W});$({elementPositions:N,elementPositionKey:W}),$({elementPositions:et,elementPositionKey:W}),o("updateBlockData",{blockId:a.value,blockData:{[W]:{minHeight:Math.max(Gb,l.value[W].minHeight-X)}},merge:!0})},U=()=>{o("leaveBlockEditMode"),M({selectedElementGroup:L.value,elementPositionKey:se}),o("removeElement",{elementId:n.value}),o("undoRedo/createSnapshot")},Y=({elementPositionKey:W,selectedElementGroup:V,shouldOverlap:K=!1,shouldNudgeElementsBelow:Z=!1})=>{const N=()=>W==="desktop"&&r.value?y.value[y.value.length-1].groupBottom:(K?b.value[W].top:V.value.groupBottom)+lr,X=b.value[W].height+lr,et=n2({elements:g.value,elementPositionKey:W,verticalTreshold:V.value.groupBottom-1}),pt=Xm({elements:et,elementPositionKey:W,shiftMargin:X});return Z||$({elementPositions:pt,elementPositionKey:W}),{newElementTop:N()}};return{elementGroupsMobile:k,elementGroupsDesktop:y,elementGroups:I,currentElementPositionKey:u,selectedElement:b,selectedElementGroupIndex:P,selectedElementGroup:D,switchElementGroupsPositions:A,elementBlockId:a,blockData:l,deleteSelectedElement:U,duplicateSelectedElement:()=>{const{newElementTop:W}=Y({selectedElementGroup:z,elementPositionKey:ge,shouldNudgeElementsBelow:!0,shouldOverlap:!r.value}),{newElementTop:V}=Y({selectedElementGroup:L,elementPositionKey:se});o("duplicateElement",{mobileTop:V,desktopTop:W,elementId:n.value}),o("undoRedo/createSnapshot")}}},Ph=C(),rm=t=>{const{getters:e}=nt(),o=C(),n=c(()=>e.currentElementId);return Rt([n],([s])=>{s||(Ph.value=null),t&&s===t.elementId&&(Ph.value=o.value.$el)}),{elementRef:o,currentElementRef:Ph}},vI=()=>{const{getters:t,dispatch:e}=nt(),{currentElementRef:o}=rm(),n=c(()=>t.currentElement),s=c(()=>t["gui/isMobileMode"]),a=c(()=>s.value?se:ge);return{resetProportions:()=>{const i=o.value.querySelector("img"),{naturalWidth:r,naturalHeight:u}=i,p=r/u,g=Math.round(n.value[a.value].width/p);g&&e("mergeCurrentElementData",{elementData:{[a.value]:{height:g}}})}}},kU={class:"mobile-controls"},IU={key:0,class:"mobile-controls__heading"},SU={class:"text-bold-2"},EU={__name:"ContextMenuLayoutElement",props:{triggerRef:{type:Element,default:null}},emits:["close-context-menu","remove-element"],setup(t,{emit:e}){const o=[Vm,jm,Um,Wm,qm,Ym,Km,Zm],n=t,s=e,{selectedLayoutElementId:a,copiedElementLocale:l,copiedElementId:i,isElementCut:r}=Sl(),{completeAchievement:u}=Ho(),{closeContextMenu:p}=Il(),{state:g,getters:b,dispatch:y}=nt(),k=fa(),I=c(()=>b.currentElementType===_n),E=c(()=>g.gui.isMobileScreen),T=c(()=>g.currentLocale),P=c(()=>b.currentElementBlockId),z=c(()=>g.currentElementId),L=c(()=>b.currentElement),D=c(()=>g.isElementEditMode),$=c(()=>b.siteBlocks),A=c(()=>{var Q;return((Q=$.value[P.value])==null?void 0:Q.zindexes)||[]}),M=c(()=>{var Q;return((Q=document.querySelector(`[data-element-ref='${z.value}']`))==null?void 0:Q.tagName)==="TEXTAREA"}),U=c(()=>b["gui/isColorPickerOpen"]),Y=c(()=>A.value[A.value.length-1]===a.value),F=c(()=>A.value[0]===a.value),{deleteSelectedElement:W,duplicateSelectedElement:V}=lm({selectedElementId:z}),{croppedImageId:K,exitCropMode:Z}=sm(),{showGalleryManager:N}=Ky(),{isAiTextGeneratorPopupVisible:X}=Zy({elementId:z.value}),et=()=>{var Q,bt;z.value&&(((Q=L.value)==null?void 0:Q.type)===Ni&&u(Ms),Se({category:"SHORTCUT:Delete element",data:{elementType:(bt=L.value)==null?void 0:bt.type,elementId:z.value}}),W())},pt=()=>{i.value=a.value,l.value=T.value,r.value=!0},st=()=>{i.value=a.value,l.value=T.value,r.value=!1},J=Q=>{y("updateBlockData",{blockId:P.value,blockData:{zindexes:Q},merge:!0})},it=Q=>{const{shouldMoveLeft:bt=!1,shouldMoveFully:wt=!1}=Q,yt=bt?g_(A.value,a.value,wt):p_(A.value,a.value,wt);J(yt)},at=()=>{a.value=null,n.triggerRef?s("close-context-menu"):p()},ot=(Q,bt)=>{!Q||!o.includes(Q)||([Vm,jm,Um,Wm].includes(Q)&&it(bt),Q===qm&&pt(),Q===Ym&&st(),Q===Km&&V(),Q===Zm&&et(),at(),a.value=null)},ft={copy:()=>!!document.querySelector("#ai-image-generator-popup")},tt=Q=>{const bt=document.getElementsByTagName("dialog").length>0;if(!(!z.value||bt)&&(He(Q)===ce.Escape&&(D.value||K.value)&&(Q.preventDefault(),y("leaveElementEditMode"),Z()),!(D.value||N.value||X.value))){if((He(Q)===ce.Backspace||He(Q)===ce.Delete)&&!U.value&&!M.value&&!Qn.value&&(Q.preventDefault(),et()),(Q.ctrlKey||Q.metaKey)&&He(Q)===ce.KeyD&&(Q.preventDefault(),V()),(Q.ctrlKey||Q.metaKey)&&He(Q)===ce.Backspace&&!M.value&&!Qn.value&&(Q.preventDefault(),et()),(Q.ctrlKey||Q.metaKey)&&He(Q)===ce.KeyC){if(ft.copy())return;Q.preventDefault(),i.value=z.value,l.value=T.value,r.value=!1}if((Q.ctrlKey||Q.metaKey)&&He(Q)===ce.KeyX&&(Q.preventDefault(),i.value=z.value,l.value=T.value,r.value=!0),(Q.ctrlKey||Q.metaKey)&&He(Q)===ce.BracketLeft){Q.preventDefault();const wt=g_(A.value,z.value,k?Q.altKey:Q.shiftKey);J(wt)}if((Q.ctrlKey||Q.metaKey)&&He(Q)===ce.BracketRight){Q.preventDefault();const wt=p_(A.value,z.value,k?Q.altKey:Q.shiftKey);J(wt)}}},{resetProportions:gt}=vI();return Nt(()=>{window.addEventListener("keydown",tt)}),so(()=>{window.removeEventListener("keydown",tt)}),(Q,bt)=>{const wt=ct("qa");return d(),S(f8,{"is-enabled":!!f(a),"trigger-ref":t.triggerRef,"is-element":"",onCloseContextMenu:at},{default:_(()=>[m("div",kU,[E.value?(d(),v("div",IU,[m("p",SU,w(Q.$t("builder.editText.moreOptions")),1),O((d(),S(ut,{"button-type":"plain",title:Q.$t("common.close"),onClick:at},{icon:_(()=>[h(lt,{name:"close"})]),_:1},8,["title"])),[[wt,"mobile-context-menu-btn-close"]])])):B("",!0),E.value?(d(),S(ye,{key:1})):B("",!0),h(zn,{icon:"cut",title:Q.$t("builder.contextMenu.gridItem.cut"),shortcut:{mac:"⌘ X",windows:"Ctrl+X"},onClick:bt[0]||(bt[0]=yt=>ot(f(qm)))},null,8,["title"]),h(zn,{icon:"file_copy",title:Q.$t("builder.contextMenu.gridItem.copy"),shortcut:{mac:"⌘ C",windows:"Ctrl+C"},onClick:bt[1]||(bt[1]=yt=>ot(f(Ym)))},null,8,["title"]),h(zn,{icon:"file_copy",title:Q.$t("common.duplicate"),shortcut:{mac:"⌘ D",windows:"Ctrl+D"},onClick:bt[2]||(bt[2]=yt=>ot(f(Km)))},null,8,["title"]),h(zn,{icon:"delete_outline",title:Q.$t("common.delete"),shortcut:{mac:"⌫",windows:"Backspace"},onClick:bt[3]||(bt[3]=yt=>ot(f(Zm)))},null,8,["title"]),h(ye),E.value?B("",!0):(d(),S(zn,{key:2,icon:"flip_to_front",title:Q.$t("builder.contextMenu.gridItem.sendFront"),shortcut:{mac:"⌥ ⌘ ]",windows:"Ctrl+Shift+]"},disabled:Y.value,onClick:bt[4]||(bt[4]=yt=>ot(f(Vm),{shouldMoveLeft:!1,shouldMoveFully:!0}))},null,8,["title","disabled"])),h(zn,{icon:"flip_to_front",title:Q.$t("builder.contextMenu.gridItem.moveForward"),disabled:Y.value,shortcut:{mac:"⌘ ]",windows:"Ctrl+]"},onClick:bt[5]||(bt[5]=yt=>ot(f(jm),{shouldMoveLeft:!1,shouldMoveFully:!1}))},null,8,["title","disabled"]),E.value?B("",!0):(d(),S(zn,{key:3,icon:"flip_to_back",title:Q.$t("builder.contextMenu.gridItem.sendBack"),shortcut:{mac:"⌥ ⌘ [",windows:"Ctrl+Shift+["},disabled:F.value,onClick:bt[6]||(bt[6]=yt=>ot(f(Um),{shouldMoveLeft:!0,shouldMoveFully:!0}))},null,8,["title","disabled"])),h(zn,{icon:"flip_to_back",title:Q.$t("builder.contextMenu.gridItem.moveBackward"),disabled:F.value,shortcut:{mac:"⌘ [",windows:"Ctrl+["},onClick:bt[7]||(bt[7]=yt=>ot(f(Wm),{shouldMoveLeft:!0,shouldMoveFully:!1}))},null,8,["title","disabled"]),I.value?(d(),S(ye,{key:4})):B("",!0),I.value?(d(),S(zn,{key:5,icon:"reset_image",title:Q.$t("builder.editImage.tabImage.resetProportions"),onClick:f(gt)},null,8,["title","onClick"])):B("",!0)])]),_:1},8,["is-enabled","trigger-ref"])}}},_I=H(EU,[["__scopeId","data-v-ad9de960"]]),xU={__name:"ElementPlaceSwitchControls",props:{elementId:{type:String,required:!0}},setup(t){const e=t,{state:o}=nt(),n=c(()=>o.gui.builderPreviewContainerRef),{elementGroups:s,currentElementPositionKey:a,switchElementGroupsPositions:l,selectedElement:i,selectedElementGroupIndex:r,selectedElementGroup:u}=lm({selectedElementId:e.elementId}),p=c(()=>r.value===0),g=c(()=>{var I;return r.value===(((I=s.value)==null?void 0:I.length)||0)-1}),b=c(()=>!p.value),y=c(()=>!g.value),k=({higherGroup:I,lowerGroup:E})=>{const T=i.value[a.value].top;l({higherGroup:I,lowerGroup:E});const P=i.value[a.value].top-T;n.value.scrollBy({top:P,behavior:"smooth"})};return(I,E)=>{const T=ct("qa");return d(),v(dt,null,[h(mo,{class:"placement-switch-top",title:I.$t("builder.editBlockButton.moveUp")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",disabled:!b.value,onClick:E[0]||(E[0]=P=>k({higherGroup:f(s)[f(r)-1],lowerGroup:f(u)}))},{icon:_(()=>[h(lt,{name:"arrow_upward"})]),_:1},8,["disabled"])),[[T,"elementplaceswitch-btn-up"]])]),_:1},8,["title"]),h(mo,{class:"placement-switch-bottom",title:I.$t("builder.editBlockButton.moveDown")},{default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",disabled:!y.value,onClick:E[1]||(E[1]=P=>k({higherGroup:f(u),lowerGroup:f(s)[f(r)+1]}))},{icon:_(()=>[h(lt,{name:"arrow_downward"})]),_:1},8,["disabled"])),[[T,"elementplaceswitch-btn-down"]])]),_:1},8,["title"])],64)}}},R_=H(xU,[["__scopeId","data-v-781de711"]]),TU=t=>(ke("data-v-3521201c"),t=t(),Ie(),t),CU={class:"element-edit-controls-bar-buttons"},PU={key:0,class:"text-body-2"},BU=TU(()=>m("span",null,w("⌫"),-1)),AU={class:"element-place-switch-controls-popup__buttons"},DU=16,zU={__name:"ElementEditControlsBar",props:{elementId:{type:String,required:!0},enterElementEditModeButtonTitle:{type:String,required:!0},isMainControlsDisabled:{type:Boolean,default:!1}},emits:["element-deleted"],setup(t,{emit:e}){const o=t,n=e,{state:s,dispatch:a,getters:l}=nt(),{currentElementRef:i}=rm(),{selectedLayoutElementId:r}=Sl(),{mousePositionX:u,mousePositionY:p,isContextMenuWithTriggerActive:g}=Il(),{deleteSelectedElement:b,duplicateSelectedElement:y}=lm({selectedElementId:o.elementId}),k=nn(),I=C(null),E=fa(),T=c(()=>s.gui.isMobileScreen),P=c(()=>s.gui.isMobileView),z=c(()=>l["gui/isMobileMode"]),L=c(()=>l.siteElements),D=c(()=>L.value[o.elementId]),$=c(()=>{var V,K;return!!((K=(V=D.value)==null?void 0:V[ge])!=null&&K.isHidden)}),A=c(()=>{var V,K;return!!((K=(V=D.value)==null?void 0:V[se])!=null&&K.isHidden)}),M=c(()=>{if(!z.value||!D.value)return DU;const{width:V,left:K}=D.value[se];return ei-V-K}),U=()=>{a("enterElementEditMode")},Y=()=>{b(),n("element-deleted")},F=({value:V,elementPositionKey:K})=>{a("mergeElementData",{elementId:o.elementId,elementData:{[K]:{isHidden:V}}})},W=({isOpen:V})=>{r.value=V?o.elementId:null,g.value=V,u.value=null,p.value=null};return(V,K)=>{const Z=ct("qa");return d(),v("div",null,[m("div",CU,[f(k).isAiTypeSelectionVisible?(d(),S(h8,{key:0,"element-id":o.elementId},null,8,["element-id"])):B("",!0),O((d(),S(ut,{"button-type":"plain",theme:"highlight",onClick:U},si({default:_(()=>[T.value?B("",!0):(d(),v("span",PU,w(t.enterElementEditModeButtonTitle),1))]),_:2},[T.value?{name:"icon",fn:_(()=>[h(lt,{name:"settings"})]),key:"0"}:void 0]),1024)),[[Z,"element-button-edit"]]),vt(V.$slots,"default",{},void 0,!0),t.isMainControlsDisabled?B("",!0):(d(),v(dt,{key:1},[h(Vo),h(mo,{title:V.$t("common.duplicate")},{shortcut:_(()=>[m("span",null,w(f(E)?"⌘D":"Ctrl+D"),1)]),default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",title:V.$t("common.duplicate"),onClick:f(y)},{icon:_(()=>[h(lt,{name:"content_copy"})]),_:1},8,["title","onClick"])),[[Z,"builder-textelementedit-buttonduplicate"]])]),_:1},8,["title"]),T.value?B("",!0):(d(),S(mo,{key:0,title:V.$t("builder.editBlockButton.hideShow")},{default:_(()=>[h(b8,{"is-hidden-desktop":$.value,"is-hidden-mobile":A.value,onSetDesktopVisibility:K[0]||(K[0]=N=>F({value:N,elementPositionKey:f(ge)})),onSetMobileVisibility:K[1]||(K[1]=N=>F({value:N,elementPositionKey:f(se)}))},null,8,["is-hidden-desktop","is-hidden-mobile"])]),_:1},8,["title"])),T.value?B("",!0):(d(),S(mo,{key:1,title:V.$t("common.delete")},{shortcut:_(()=>[BU]),default:_(()=>[O((d(),S(ut,{"button-type":"plain",theme:"highlight",title:V.$t("common.delete"),onClick:Y},{icon:_(()=>[h(lt,{name:"delete"})]),_:1},8,["title"])),[[Z,"builder-textelementedit-buttondelete"]])]),_:1},8,["title"])),h(Vo),T.value?(d(),S(R_,{key:2,"element-id":o.elementId},null,8,["element-id"])):B("",!0),T.value?(d(),S(Vo,{key:3})):B("",!0),h(mo,{title:V.$t("common.more")},{default:_(()=>[O((d(),S(ut,{ref_key:"contextMenuButtonRef",ref:I,"button-type":"plain",theme:"highlight",title:V.$t("builder.contextMenuTitle"),onClick:K[2]||(K[2]=N=>W({isOpen:!f(g)}))},{icon:_(()=>[h(lt,{name:"more_vert"})]),_:1},8,["title"])),[[Z,"builder-elementedit-buttoncontext"]])]),_:1},8,["title"])],64))]),f(g)?(d(),S(_I,{key:0,"trigger-ref":I.value&&I.value.$el,onCloseContextMenu:K[3]||(K[3]=N=>W({isOpen:!1}))},null,8,["trigger-ref"])):B("",!0),P.value&&!t.isMainControlsDisabled?(d(),S(ve,{key:1,ref:"popup","target-ref":f(i),"portal-selector":f(So),placement:"right","auto-update":"",offset:M.value},{default:_(()=>[m("div",AU,[h(R_,{"element-id":o.elementId},null,8,["element-id"])])]),_:1},8,["target-ref","portal-selector","offset"])):B("",!0)])}}},M_=H(zU,[["__scopeId","data-v-3521201c"]]),li=t=>{const{dispatch:e,getters:o}=nt(),n=c(()=>o.siteElements),s=c(()=>n.value[t.elementId]),a=c(()=>{var i;return(i=s.value)==null?void 0:i.type}),l=()=>{Se({category:"CONTROLS:ELEMENT",message:"Close",data:{currentElementId:t.elementId,type:a.value},level:"debug",type:"debug"}),e("leaveElementEditMode"),e("undoRedo/createSnapshot")};return Nt(()=>{Se({category:"CONTROLS:ELEMENT",message:"Created",data:{currentElementId:t.elementId,type:a.value},level:"debug",type:"debug"})}),{closeElementEditPopupHandler:l}},ri={__name:"ElementEditControls",props:{elementId:{type:String,required:!0},isElementActive:{type:Boolean,default:!1},targetRef:{type:[HTMLElement,null],default:null},enterEditModeButtonTitle:{type:String,default:""},editModePopupOptions:{type:Object,default:()=>({placement:"right-start",offset:18,flip:!1,autoUpdate:!1})},controlsPopupOptions:{type:Object,default:()=>({placement:"top-start",offset:22,flip:!1,autoUpdate:!0})},isMobilePopupStickedToBottom:{type:Boolean,default:!1},isMainControlsDisabled:{type:Boolean,default:!1},isNonGridElementEditMode:{type:Boolean,default:!1},isNonGridElementControlsVisible:{type:Boolean,default:!1},nonGridElementRef:{type:HTMLElement,default:null},isEditControlsHidden:{type:Boolean,default:!1}},emits:["element-deleted"],setup(t,{emit:e}){const o=t,n=e,{state:s,getters:a}=nt(),{currentElementRef:l}=rm(),{closeElementEditPopupHandler:i}=li({elementId:o.elementId}),r=c(()=>o.isNonGridElementEditMode||s.isElementEditMode),u=c(()=>a.currentElementId),p=c(()=>a["gui/isColorPickerOpen"]),g=c(()=>s.gui.isMobileScreen),b=c(()=>o.isElementActive),y=c(()=>(o.isNonGridElementControlsVisible||u.value===o.elementId&&!(b!=null&&b.value))&&!o.isEditControlsHidden),k=I=>{p.value||I.button!==0&&i()};return(I,E)=>y.value?(d(),S(Ee,{key:0,to:"body"},[r.value&&t.targetRef?(d(),S(ve,{key:0,"target-ref":t.targetRef,placement:t.editModePopupOptions.placement,offset:t.editModePopupOptions.offset,"auto-update":t.editModePopupOptions.autoUpdate,flip:t.editModePopupOptions.flip,"is-mobile-fixed-to-bottom":!t.isMobilePopupStickedToBottom,"is-controls":"","is-mobile-sticked-to-bottom":t.isMobilePopupStickedToBottom,"portal-selector":f(So),"ignore-target-position-change":"",onClickOutside:k},{default:_(()=>[vt(I.$slots,"edit-mode-popup")]),_:3},8,["target-ref","placement","offset","auto-update","flip","is-mobile-fixed-to-bottom","is-mobile-sticked-to-bottom","portal-selector"])):g.value?(d(),S(Ee,{key:1,to:f(r3)},[h(M_,{"enter-element-edit-mode-button-title":t.enterEditModeButtonTitle,"element-id":o.elementId,onElementDeleted:E[0]||(E[0]=T=>n("element-deleted"))},{default:_(()=>[vt(I.$slots,"additional-edit-buttons")]),_:3},8,["enter-element-edit-mode-button-title","element-id"])],8,["to"])):(d(),S(ve,{key:2,"target-ref":t.nonGridElementRef||f(l),"portal-selector":f(So),placement:t.controlsPopupOptions.placement,"is-controls":"","auto-update":t.controlsPopupOptions.autoUpdate,flip:t.controlsPopupOptions.flip,offset:t.controlsPopupOptions.offset},{default:_(()=>[h(M_,{"enter-element-edit-mode-button-title":t.enterEditModeButtonTitle,"element-id":o.elementId,"is-main-controls-disabled":t.isMainControlsDisabled,onElementDeleted:E[1]||(E[1]=T=>n("element-deleted"))},{default:_(()=>[vt(I.$slots,"additional-edit-buttons")]),_:3},8,["enter-element-edit-mode-button-title","element-id","is-main-controls-disabled"])]),_:3},8,["target-ref","portal-selector","placement","auto-update","flip","offset"]))])):B("",!0)}},$U=q({__name:"GridButton",props:{tagName:{default:"a"},href:{default:null},target:{default:null},rel:{default:null},type:{default:"primary"},buttonType:{default:null},content:{default:""},isDisabled:{type:Boolean,default:!1},isLoading:{type:Boolean,default:!1},fontSizeMobile:{default:null},fontSizeDesktop:{default:null},fontFamily:{default:null},fontWeight:{default:null},borderWidth:{default:null},borderRadius:{default:null},backgroundColor:{default:null},fontColor:{default:null},borderColor:{default:null},backgroundColorHover:{default:null},fontColorHover:{default:null},borderColorHover:{default:null},mobileElementWidth:{default:0},mobileElementHeight:{default:0},isInBuilder:{type:Boolean,default:!1}},emits:["click","drag","dragstart"],setup(t){const e=t,o=c(()=>`${e.mobileElementWidth*100/ei}vw`),n=c(()=>`${e.mobileElementHeight*100/ei}vw`),s=c(()=>({"--font-size-mobile":e.fontSizeMobile?`${e.fontSizeMobile}px`:null,"--font-size-desktop":e.fontSizeDesktop?`${e.fontSizeDesktop}px`:null,"--font-family":e.fontFamily,"--font-weight":e.fontWeight,"--border-radius":e.borderRadius===0||e.borderRadius?`${e.borderRadius}px`:null,"--border-width":e.borderWidth===0||e.borderWidth?`${e.borderWidth}px`:"0px","--background-color":e.backgroundColor,"--font-color":e.fontColor,"--border-color":e.borderColor||"rgb(26, 26, 26)","--background-color-hover":e.backgroundColorHover,"--font-color-hover":e.fontColorHover,"--border-color-hover":e.borderColorHover,"--m-height":e.isInBuilder?"100%":n.value,"--m-width":e.isInBuilder?"100%":o.value})),a=c(()=>({"grid-button--empty":!e.content,[`grid-button--${e.type}`]:e.type,loading:e.isLoading}));return(l,i)=>(d(),S(yo(l.tagName),{type:l.buttonType,name:l.buttonType,href:l.href,disabled:l.isDisabled,target:l.target,rel:l.rel,class:rt(["grid-button",a.value]),"aria-hidden":l.isLoading,style:ne(s.value),onClick:i[0]||(i[0]=r=>l.$emit("click",r)),onDrag:i[1]||(i[1]=r=>l.$emit("drag",r)),onDragstart:i[2]||(i[2]=r=>l.$emit("dragstart",r))},{default:_(()=>[j(w(l.content),1)]),_:1},40,["type","name","href","disabled","target","rel","class","aria-hidden","style"]))}}),sa=H($U,[["__scopeId","data-v-4a176f12"]]),LU={class:"datalist__no-results text-body-2"},OU=q({__name:"ZyroSelect",props:{options:{},inputId:{},labelKey:{},placeholder:{default:""},modelValue:{},taggable:{type:Boolean},createOption:{},filterable:{type:Boolean,default:!0},filterBy:{},searchable:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1},shouldOpenDropdownOnInput:{type:Boolean,default:!1},isInfiniteScrollEnabled:{type:Boolean,default:!1},totalOptionsCount:{},error:{default:""},selectable:{type:Function,default:()=>!0},isArrowVisible:{type:Boolean}},emits:["update:model-value","search","option:created","blur","load-more","open"],setup(t,{emit:e}){const o=e,n=t,s=C(null),a=C(!1),l=C(null),i=c(()=>n.totalOptionsCount&&n.options.lengthn.shouldOpenDropdownOnInput?!!g.length:a.value,u=async()=>{var g;o("open"),a.value=!0,await $e(),!(!n.isInfiniteScrollEnabled||n.totalOptionsCount===n.options.length||!s.value)&&((g=l.value)==null||g.observe(s.value))},p=()=>{var g;a.value=!1,n.isInfiniteScrollEnabled&&((g=l.value)==null||g.disconnect())};return Nt(()=>{n.isInfiniteScrollEnabled&&(l.value=new IntersectionObserver(async([{isIntersecting:g,target:b}])=>{if(g){const y=b.offsetParent,{scrollTop:k}=b.offsetParent;o("load-more"),await $e(),y.scrollTop=k}}))}),(g,b)=>{var k;const y=ct("qa");return d(),v("div",{class:rt(["datalist",[{"datalist--opened":a.value},{"datalist--error":g.error}]])},[O((d(),S(f(Mx),{"input-id":g.inputId,class:rt(["datalist__select",[{"datalist__select--disabled":g.disabled}]]),options:g.options,"model-value":g.modelValue,placeholder:g.placeholder,label:g.labelKey,filterable:g.filterable,taggable:g.taggable,"create-option":g.createOption,"dropdown-should-open":r,selectable:g.selectable,searchable:g.searchable,"filter-by":g.filterBy,disabled:g.disabled,"onUpdate:modelValue":b[0]||(b[0]=I=>g.$emit("update:model-value",I)),onOpen:u,onClose:p,onSearch:b[1]||(b[1]=I=>g.$emit("search",I)),"onSearch:blur":b[2]||(b[2]=I=>g.$emit("blur",I))},{"open-indicator":_(()=>[O(h(lt,{class:"datalist__select-arrow",name:"expand_more"},null,512),[[Qe,!g.isArrowVisible]])]),"no-options":_(()=>[m("div",LU,w(g.$t("common.searchNoResults")),1)]),option:_(I=>[vt(g.$slots,"option",{option:I},void 0,!0)]),"selected-option":_(I=>[vt(g.$slots,"selected-option",{option:I},void 0,!0)]),"list-footer":_(()=>[O(m("li",{ref_key:"infiniteScrollTriggerRef",ref:s,class:"datalist__loader-wrapper"},[h(Ue,{size:"16px",weight:"2px",color:"black"})],512),[[Qe,g.isInfiniteScrollEnabled&&i.value]])]),_:3},8,["input-id","class","options","model-value","placeholder","label","filterable","taggable","create-option","selectable","searchable","filter-by","disabled"])),[[y,`dropdown-button-select-${((k=g.modelValue)==null?void 0:k[g.labelKey])??""}`]])],2)}}}),co=H(OU,[["__scopeId","data-v-a274c808"]]),RU=q({props:{title:{type:String,default:""},subtitle:{type:String,default:""}}}),MU={class:"empty-block"},HU={key:0,class:"empty-block__title text-bold-2"},NU={key:1,class:"text-body-2"};function GU(t,e,o,n,s,a){return d(),v("div",MU,[t.title?(d(),v("h3",HU,w(t.title),1)):B("",!0),t.subtitle?(d(),v("p",NU,w(t.subtitle),1)):B("",!0)])}const lg=H(RU,[["render",GU],["__scopeId","data-v-14c023db"]]),FU={class:"link-settings-file-download"},VU={key:0,class:"link-settings-file-download__selected-file"},UU={class:"link-settings-file-download__selected-file-name text-body-2"},jU={class:"link-settings-file-download__select-file-container"},WU=q({__name:"LinkSettingsFileDownload",props:{href:{default:null}},emits:["update:href","update:target"],setup(t,{emit:e}){const o=t,n=e,s=C(!1),{t:a}=_t(),l=c(()=>o.href?a("builder.linkSettingsChangeFile"):a("builder.linkSettingsSelectFile")),i=()=>{s.value=!1},r=(p={url:null})=>{n("update:href",p.url),i()},u=()=>{n("update:href",null),n("update:target",null)};return(p,g)=>{const b=ct("qa");return d(),v("div",FU,[p.href?(d(),v("div",VU,[h(qt,{name:"document",class:"link-settings-file-download__selected-file-document-icon"}),m("p",UU,w(f(Ny)(p.href,!0)),1),h(ut,{class:"link-settings-file-download__selected-file-x-icon","button-type":"plain",theme:"highlight",onClick:u},{icon:_(()=>[h(lt,{name:"close"})]),_:1})])):(d(),S(lg,{key:1,class:"link-settings-file-download__empty-pages-block",subtitle:p.$t("builder.linkSettingsNoFileSelected")},null,8,["subtitle"])),m("div",jU,[O((d(),S(ut,{onClick:g[0]||(g[0]=y=>s.value=!0)},{default:_(()=>[j(w(l.value),1)]),_:1})),[[b,"button-select-file"]])]),s.value?(d(),S(Ee,{key:2,to:"body"},[h(Ra,{"visible-categories":[f(Bo).DOCUMENT,f(Bo).IMAGE],onUpdateTarget:g[1]||(g[1]=y=>p.$emit("update:target","_blank")),onSelectImage:r,onClose:i},null,8,["visible-categories"])])):B("",!0)])}}}),qU=H(WU,[["__scopeId","data-v-8f1ebf70"]]),YU=t=>(ke("data-v-fffa1509"),t=t(),Ie(),t),KU={class:"text-bold-2 link-settings__label"},ZU={key:0,class:"link-settings__selected-type"},QU={class:"link-type-option"},XU={class:"link-type-option__left"},JU={key:0},tj={class:"anchor-id"},ej=YU(()=>m("br",null,null,-1)),oj=q({__name:"LinkSettings",props:{target:{default:"_self"},href:{default:""},rel:{},type:{default:"page"},pageId:{default:""}},emits:["update:type","update:href","update:pageId","update:target","update:rel"],setup(t,{emit:e}){const o=Un.HTTPS,n=Object.values(Un),s={value:"",type:oe.PAGE},a=t,l=e,{t:i}=_t(),{getters:r,state:u}=nt(),p=me(),{isAiBuilderMode:g}=vo(),b=c(()=>r.sitePages),y=c(()=>r.siteBlocks),k=c(()=>u.currentLocale!==r.defaultLocale?`/${u.currentLocale}`:""),I=c(()=>r.isCurrentPagePrivate),E=c(()=>r.privatePage||{}),T=()=>{if(!a.href.includes("#"))return s;const[mt,Ct]=a.href.split("#"),xt=mt.replace(`${k.value}/`,""),Ht=!xt||xt==="/"?r.sitePages[r.homePageId]:Object.values(b.value).find(Lt=>xt.replace("/","")===Lt.slug);if(!Ht)return s;const Gt=I.value?E.value.name:Ht.name;return{value:Ct,title:Gt,slug:a.href,type:oe.ANCHORED_SECTION}},P=(mt,Ct)=>{var Ht;const xt=p.productsSeoWithUpdates.find(Gt=>Gt.id===mt.productId);return{title:mt.name||(xt==null?void 0:xt.title),value:Ct,type:oe.PAGE,slug:(Ht=xt==null?void 0:xt.seo_settings)==null?void 0:Ht.slug,isProductPage:!0}},z=(mt,Ct)=>p.productsSeoWithUpdates.map(xt=>({title:xt.title,value:Ct,type:oe.PAGE,slug:xt.seo_settings.slug,isProductPage:!0})),L=()=>{var Ct,xt;const mt=b.value[a.pageId];if(!mt)return s;if(mt.type===un)return P(mt,a.pageId);if(mt.type===Uo){const Ht=(Ct=a.href.match(/\/([^/]+)/))==null?void 0:Ct[1],Gt=p.productsSeoWithUpdates.find(Lt=>Lt.seo_settings.slug===Ht);return{title:(Gt==null?void 0:Gt.seo_settings.title)||(Gt==null?void 0:Gt.title),value:a.pageId,type:oe.PAGE,slug:Ht}}return{title:mt.type===ka?(xt=mt.meta)==null?void 0:xt.title:mt.name,value:a.pageId,type:oe.PAGE,slug:mt.slug}},$=C(a.type===oe.PAGE?L():a.href?a.type===oe.ANCHORED_SECTION?T():{value:a.href,type:a.type}:s),A=C(!1),M=C(!0),U=ie(),Y=c(()=>[{title:i("builder.linkSettingsPage"),icon:"draft",type:oe.PAGE},{title:i("builder.linkSettingsCustomLink"),icon:"link",type:oe.EXTERNAL},{title:i("builder.linkSettingsSection"),icon:"calendar_view_day",type:oe.ANCHORED_SECTION},{title:i("builder.linkSettingsEmailAddress"),icon:"mail",type:oe.EMAIL},{title:i("builder.linkSettingsPhoneNumber"),icon:"call",type:oe.PHONE},...g.value?[]:[{title:i("builder.linkSettingsFileDownload"),icon:"description",type:oe.DOWNLOAD}]]),W=C(a.href?a.type:oe.PAGE),V=C(oe.PAGE),K=c(()=>Y.value.find(mt=>W.value===mt.type)),Z=c(()=>({email:i("builder.editButton.linkSettings.emailPlaceholder"),external:"https://www.example.com",phone:i("builder.editButton.linkSettings.phonePlaceholder")})),N=c(()=>Object.values(y.value).find(mt=>{const{htmlId:Ct,slot:xt}=mt;return!!Ct&&xt==="footer"})),X=mt=>mt===r.homePageId,et=c(()=>[...Object.entries(y.value).filter(([mt,Ct])=>{var Ht,Gt;const xt=I.value?(Ht=E.value.blocks)==null?void 0:Ht.includes(mt):!((Gt=E.value.blocks)!=null&&Gt.includes(mt));return!!Ct.htmlId&&Ct.slot!=="footer"&&xt}).map(([mt,Ct])=>{const{htmlId:xt}=Ct,[Ht,Gt]=Object.entries(b.value).find(([,{blocks:Tt}])=>(Tt||[]).includes(mt)),Lt=X(Ht)?`/#${xt}`:`/${Gt.slug}#${xt}`;return{value:xt,title:Gt.name,slug:`${k.value}${Lt}`,type:oe.ANCHORED_SECTION}}),...N.value?[{value:N.value.htmlId,title:r.currentPage.name,slug:X(u.currentPageId)?`${k.value}/#${N.value.htmlId}`:`${k.value}/${r.currentPage.slug}#${N.value.htmlId}`,type:oe.ANCHORED_SECTION}]:[]]),pt=C(et.value.length?i("builder.editButton.linkSettings.anchoredSectionPlaceholder"):i("builder.editButton.linkSettings.noNamedSections")),st=mt=>W.value===mt,J=c(()=>st(oe.EXTERNAL)||st(oe.EMAIL)||st(oe.PHONE)),it=c(()=>st(oe.PAGE)||st(oe.EXTERNAL)||st(oe.ANCHORED_SECTION)),at=c(()=>st(oe.EXTERNAL)||st(oe.ANCHORED_SECTION)),ot=c(()=>Object.entries(b.value).filter(([,mt])=>mt.type!==ll).flatMap(([mt,Ct])=>{var Ht;if(Ct.type===un)return P(Ct,mt);if(Ct.type===Uo)return z(Ct,mt);const xt=X(mt)?"":Ct.slug;return{title:Ct.type===ka?(Ht=Ct.meta)==null?void 0:Ht.title:Ct.name,value:mt,type:oe.PAGE,slug:xt}})),ft=({newValue:mt,isValid:Ct=!0})=>{M.value=Ct,Ct&&l("update:href",mt||"")},tt=mt=>{if(mt.value){if(mt.type===oe.EXTERNAL){const xt=n.some(Gt=>mt.value.startsWith(Gt))?mt.value:`${o}${mt.value}`,Ht=H3(xt);if(!Ht.isUrlValid){ft({isValid:!1});return}ft({newValue:Ht.url});return}if(mt.type===oe.EMAIL){const Ct=dy(mt.value);if(!Ct.isUrlValid){ft({isValid:!1});return}ft({newValue:Ct.url});return}if(mt.type===oe.PHONE){const Ct=O9(mt.value);if(!Ct.isUrlValid){ft({isValid:!1});return}ft({newValue:Ct.url});return}if(mt.type===oe.PAGE){let Ct=k.value&&mt.slug?`${k.value}/`:k.value;(!k.value||mt.isProductPage)&&(Ct="/"),ft({newValue:`${Ct}${mt.slug}`}),l("update:pageId",mt.value)}mt.type===oe.ANCHORED_SECTION&&(ft({newValue:mt.slug}),l("update:pageId",mt.value))}},gt=mt=>{if(typeof mt=="string"){$.value={value:mt,type:W.value};return}$.value=mt},Q=()=>{A.value=!0,tt($.value)};Rt(()=>$.value,mt=>tt(mt),{deep:!0}),Rt(()=>a.type,mt=>{W.value=mt},{immediate:!0});const bt=()=>{W.value=V.value},wt=mt=>{mt&&(W.value=mt.type,V.value=mt.type,$.value=s,A.value=!1,M.value=!0,l("update:type",mt.type),l("update:href",""),l("update:pageId",""),l("update:rel",""),l("update:target","_self"),mt.type===oe.EXTERNAL&&(l("update:rel","nofollow"),l("update:target","_blank")))},yt=()=>{l("update:target",a.target==="_blank"?"_self":"_blank")},At=()=>{l("update:rel",a.rel==="nofollow"?"":"nofollow")};return(mt,Ct)=>{const xt=G("i18n-t"),Ht=ct("qa");return d(),v("div",null,[m("p",KU,w(mt.$t("builder.editButton.linkSettings.label")),1),O((d(),S(co,{modelValue:W.value,"onUpdate:modelValue":[Ct[0]||(Ct[0]=Gt=>W.value=Gt),wt],"label-key":"title",options:Y.value,class:"link-settings__input-dropdown",label:mt.$t("builder.editButton.linkSettings.label"),onBlur:bt},{"selected-option":_(()=>[K.value?O((d(),v("div",ZU,[h(lt,{name:K.value.icon,dimensions:"20px"},null,8,["name"]),j(" "+w(K.value.title),1)])),[[Ht,"link-settings-selected-link-type"]]):B("",!0)]),option:_(({option:Gt})=>[O((d(),v("div",QU,[m("div",XU,[h(lt,{name:Gt.icon,dimensions:"20px"},null,8,["name"]),j(" "+w(Gt.title),1)]),Gt.type===W.value?(d(),S(lt,{key:0,name:"check",dimensions:"20px"})):B("",!0)])),[[Ht,`dropdown-option-${Gt.title}`]])]),_:1},8,["modelValue","options","label"])),[[Ht,"linksettingsmodal-inputdropdown-page"]]),st(f(oe).DOWNLOAD)?(d(),S(qU,{key:0,href:mt.href,"onUpdate:target":Ct[1]||(Ct[1]=Gt=>mt.$emit("update:target",Gt)),"onUpdate:href":Ct[2]||(Ct[2]=Gt=>mt.$emit("update:href",Gt))},null,8,["href"])):(d(),v(dt,{key:1},[st(f(oe).ANCHORED_SECTION)?(d(),v("div",JU,[O((d(),S(co,{class:"link-settings__anchored-section-datalist","label-key":"slug",options:et.value,"model-value":$.value.value?$.value.value:null,placeholder:pt.value,disabled:!et.value.length,"onUpdate:modelValue":gt},{"selected-option":_(()=>[h(xt,{tag:"span",keypath:"builder.editButton.linkSettings.anchorInPage",class:"anchored-section__search-value"},{default:_(()=>[m("span",tj,w($.value.value),1),O((d(),v("span",null,[j(w($.value.title),1)])),[[Ht,"section-link-dropdown-active-item"]])]),_:1})]),option:_(({option:Gt})=>[m("span",null,w(Gt.value),1),ej,h(xt,{tag:"span",keypath:"builder.editButton.linkSettings.anchorWithPageSuffix",class:"anchored-section__option-page-name"},{default:_(()=>[j(w(Gt.title),1)]),_:2},1024)]),_:1},8,["options","model-value","placeholder","disabled"])),[[Ht,"section-link-dropdown"]])])):B("",!0),st(f(oe).PAGE)?O((d(),S(co,{key:1,class:"link-settings__anchored-section-datalist",options:ot.value,"label-key":"title","model-value":$.value.value?$.value.value:null,placeholder:f(i)("builder.editButton.linkSettings.pagePlaceholder"),"onUpdate:modelValue":gt},{"selected-option":_(()=>[O((d(),v("span",null,[j(w($.value.title),1)])),[[Ht,"page-link-dropdown-active-item"]])]),option:_(({option:Gt})=>[m("span",null,w(Gt.title),1)]),_:1},8,["options","model-value","placeholder"])),[[Ht,"page-link-dropdown"]]):B("",!0),J.value?O((d(),S(Ge,{key:2,id:`${f(U)}-link`,"model-value":$.value.value?$.value.value:"","qa-selector":"linksettingsmodal-input",placeholder:Z.value[W.value],error:!M.value&&mt.$t("validate.url"),onInputBlur:Q,"onUpdate:modelValue":gt},null,8,["id","model-value","placeholder","error"])),[[Ht,"new-link-url-input-field"]]):B("",!0),it.value?O((d(),S(eo,{key:3,id:`${f(U)}-toggle-openinnewtab`,class:"link-settings__toggle","model-value":mt.target==="_blank",label:mt.$t("builder.editButton.linkSettings.toggleFieldLabel"),"onUpdate:modelValue":yt},null,8,["id","model-value","label"])),[[Ht,"linksettingsmodal-inputtoggle-openinnewtab"]]):B("",!0),at.value?O((d(),S(eo,{key:4,id:`${f(U)}-toggle-relnofollow`,class:"link-settings__toggle","model-value":mt.rel==="nofollow",label:mt.$t("builder.editButton.linkSettings.toggleRelNoFollowFieldLabel"),message:mt.$t("builder.editButton.linkSettings.toggleRelNoFollowFieldDescription"),"onUpdate:modelValue":At},null,8,["id","model-value","label","message"])),[[Ht,"linksettingsmodal-inputtoggle-relnofollow"]]):B("",!0)],64))])}}}),dm=H(oj,[["__scopeId","data-v-fffa1509"]]),wI=q({__name:"EditButtonTabAction",props:{elementId:{}},setup(t){const e=t,o=["GridStripeButton","GridEcommerceButton"],{getters:n,dispatch:s}=nt(),a=C(e.elementId),l=c(()=>a.value?n.siteElements[a.value]:null),i=c(()=>{var u;return o.includes((u=l.value)==null?void 0:u.type)}),r=(u,p)=>{s("mergeElementData",{elementId:a.value,elementData:{[u]:p}})};return(u,p)=>(d(),v("div",null,[h(Ge,{"model-value":l.value.content,"qa-selector":"linksettingsmodal-input-name",maxlength:"150",label:u.$t("builder.editButton.tabActionLabel"),placeholder:u.$t("builder.editButton.tabActionLabel"),"onUpdate:modelValue":p[0]||(p[0]=g=>r("content",g))},null,8,["model-value","label","placeholder"]),i.value?B("",!0):(d(),S(dm,{key:0,target:l.value.target,href:l.value.href,rel:l.value.rel,type:l.value.linkType,"page-id":l.value.linkedPageId,"onUpdate:href":p[1]||(p[1]=g=>r("href",g)),"onUpdate:rel":p[2]||(p[2]=g=>r("rel",g)),"onUpdate:target":p[3]||(p[3]=g=>r("target",g)),"onUpdate:type":p[4]||(p[4]=g=>r("linkType",g)),"onUpdate:pageId":p[5]||(p[5]=g=>r("linkedPageId",g))},null,8,["target","href","rel","type","page-id"]))]))}}),kI="https://builder-backend.hostinger.com/v3/nps",nj=async t=>(await Ut.get(`${kI}/last-evaluation/${t}`)).data,II=async({score:t,comment:e,formType:o,device:n,importedWebsiteUrl:s,siteId:a,checkboxesData:l=[]})=>Ut.post(`${kI}`,{score:t,comment:e,formType:o,device:n,importedWebsiteUrl:s,siteId:a,...(l==null?void 0:l.length)&&{checkboxes:l}}),di=Wo(en.NPS,()=>{const t=C(!1),e=C(""),o=C({titleI18Key:"",formType:el,maxScoreI18Key:"",lowestScoreI18Key:"",importedWebsiteUrl:""}),n=C(!1),s=p=>{t.value=p},a=p=>{e.value=p},l=({formType:p,importedWebsiteUrl:g=""})=>{if(!z1[p])throw new Error(`Unknown "${p}" was used`);o.value={...z1[p],importedWebsiteUrl:g}};return{isNpsVisible:t,question:e,npsData:o,isMarketingToolsSurveySent:n,setNpsVisible:s,setNpsQuestion:a,updateNpsData:l,refetchNpsModalVisibilityStatus:async({formType:p}={})=>{try{const{daysPassed:g}=await nj(el),b=g>CB||g===null,y=Do(g4)!=="true",k=b&&y;k&&l({formType:p||el}),s(k)}catch(g){jt(g),s(!1)}},setNpsData:({isVisible:p,formType:g,importedWebsiteUrl:b,newQuestion:y})=>{l({formType:g||el,importedWebsiteUrl:b}),y&&a(y),s(p)},setIsMarketingToolsSurveySent:p=>{n.value=p}}}),ij={key:0,class:"rate-feature__text"},sj={__name:"NpsRateFeature",props:{featureName:{type:String,required:!0},type:{type:String,required:!0},isDescriptionDisabled:{type:Boolean,default:!1},hideBorder:{type:Boolean,default:!1}},setup(t){const e=t,{t:o}=_t(),{isAiBuilderMode:n}=vo(),s=di(),a=()=>{s.setNpsData({newQuestion:`${o("builder.npsRateQuestion")} ${e.featureName}`,isVisible:!0,formType:e.type})};return(l,i)=>{const r=G("i18n-t");return f(n)?B("",!0):(d(),v("div",{key:0,class:rt(["rate-feature",{"rate-feature--description-disabled":t.isDescriptionDisabled}])},[m("div",{class:rt(["rate-feature__container",{"rate-feature__container--with-border":!t.hideBorder}])},[m("a",{target:"_blank",class:"rate-feature__link rate-feature__link--icon z-link",onClick:a},[h(lt,{name:"add_reaction",color:"gray",dimensions:"20px"})]),t.isDescriptionDisabled?B("",!0):(d(),v("p",ij,[h(r,{tag:"p",keypath:"builder.editImage.tabSeo.NpsImage"},{default:_(()=>[m("a",{"data-qa":"feature-nps-modal-link",target:"_blank",class:"rate-feature__link z-link",onClick:a},w(l.$t("builder.editImage.tabSeo.NpsImageRateThisFeature")),1)]),_:1})]))],2)],2))}}},_o=H(sj,[["__scopeId","data-v-c2a1ece2"]]),aj=q({components:{NpsRateFeature:_o,HostingerButton:ut},setup(){const{redirectToEcommerceProducts:t}=qo();return{redirectToEcommerceProducts:t,NPS_TYPE_FEATURE_SIMPLE_STORE:Cc}},methods:{...on({openModal:De,closeModal:Te})}}),lj={class:"ecommerce-no-products"},rj={class:"ecommerce-no-products__text text-body-1"};function dj(t,e,o,n,s,a){const l=G("HostingerButton"),i=G("NpsRateFeature"),r=ct("qa");return d(),v("div",null,[m("div",lj,[m("p",rj,w(t.$t("builder.editButton.ecommerce.noProducts")),1),O((d(),S(l,{"button-type":"outlined",onClick:t.redirectToEcommerceProducts},{default:_(()=>[j(w(t.$t("builder.editButton.ecommerce.addProducts")),1)]),_:1},8,["onClick"])),[[r,"ecommerce-settings-button-addproducts"]])]),h(i,{"feature-name":t.$t("builder.npsRateOnlineStore"),type:t.NPS_TYPE_FEATURE_SIMPLE_STORE},null,8,["feature-name","type"])])}const SI=H(aj,[["render",dj],["__scopeId","data-v-371b76e5"]]),cj={class:"ecommerce-tab"},uj=["aria-disabled"],pj={key:0,class:"ecommerce-tab__dropdown-prefix"},gj={class:"text-body-2"},mj={class:"ecommerce-tab__dropdown-option"},bj={key:0,class:"ecommerce-tab__dropdown-prefix"},fj=q({__name:"EditButtonTabEcommerce",setup(t){const{t:e}=_t(),{state:o,getters:n,dispatch:s}=nt(),a=Fn(),l=me(),i={id:-1,title:e("builder.ecommerce.chooseProduct")},r=C(0),u=c(()=>n.currentElementSettings),p=c(()=>l.products),g=c(()=>{const{productId:A}=u.value;return p.value.find(M=>M.id===A)}),b=c(()=>{var M;const{productVariantId:A}=u.value;return(M=g.value)==null?void 0:M.variants.find(U=>U.id===A)}),y=c(()=>g.value||i),k=c(()=>b.value||i),I=c(()=>y.value.id!==-1),E=c(()=>I.value?!!y.value.options.length:!1),T=c(()=>p.value.map(A=>{var U;const[M]=A.variants;return{id:A.id,disabled:(U=A.custom_fields)==null?void 0:U.some(({is_required:Y})=>Y),title:A.title,defaultVariantId:M.id,sku:A.options.length?null:M.sku}})),P=c(()=>o.gui.isMobileScreen),z=async()=>{await Et.logEvent({eventName:"website_builder.ecomm_products.edit",eventProperties:{location:"button"}}),a.setIsEcommerceAdminIframeOpen({isOpen:!0,path:lo.PRODUCTS_EDIT,params:{[No.PRODUCT]:y.value.id}})},L=A=>{s("mergeCurrentElementData",{elementData:{settings:{productId:A.id,productVariantId:A.defaultVariantId}}})},D=A=>{s("mergeCurrentElementData",{elementData:{settings:{productVariantId:A.id}}})},$=async()=>{l.count!==p.value.length&&(r.value+=1,await l.fetchProducts({limit:25*r.value}))};return Nt(async()=>{await $()}),(A,M)=>{const U=ct("qa");return d(),v("div",cj,[p.value.length?(d(),v(dt,{key:1},[h(Xt,{class:"ecommerce-tab__label"},{default:_(()=>[j(w(A.$t("builder.editButton.ecommerce.connectButtonTo")),1)]),_:1}),O((d(),S(co,{class:"ecommerce-tab__dropdown",options:T.value,"label-key":"title","model-value":y.value,"is-lazyload-enabled":"","total-options-count":f(l).count,selectable:Y=>!Y.disabled,onLoadMore:$,"onUpdate:modelValue":L},{option:_(({option:Y})=>[O((d(),v("div",{"aria-disabled":Y.disabled,class:rt(["ecommerce-tab__dropdown-option",{"ecommerce-tab__dropdown-option--disabled":Y.disabled}])},[m("div",null,[Y.sku?(d(),v("span",pj,w(`SKU ${Y.sku}`),1)):B("",!0),j(" "+w(Y.title),1)]),Y.disabled?(d(),S(Mo,{key:0,position:P.value?"top":"bottom","toggle-event":"hover",mode:"dark","use-portal":!P.value,"forced-position":P.value?{left:"0px",top:"130px","white-space":"wrap"}:void 0},{trigger:_(()=>[h(lt,{name:"help-circle",dimensions:"15px"})]),default:_(()=>[m("p",gj,w(A.$t("builder.cannotAssignCustomField")),1)]),_:1},8,["position","use-portal","forced-position"])):B("",!0)],10,uj)),[[U,`dropdown-option-${Y.title}`]])]),_:1},8,["options","model-value","total-options-count","selectable"])),[[U,"ecommerce-button-product-select"]]),E.value?(d(),v(dt,{key:0},[h(Xt,{class:"ecommerce-tab__label"},{default:_(()=>[j(w(A.$t("builder.editButton.ecommerce.productOption"))+": ",1)]),_:1}),O((d(),S(co,{class:"ecommerce-tab__dropdown",options:y.value.variants,"label-key":"title","model-value":k.value,"onUpdate:modelValue":D},{option:_(({option:Y})=>[O((d(),v("div",mj,[Y.sku?(d(),v("span",bj,w(`SKU ${Y.sku}`),1)):B("",!0),j(" "+w(Y.title),1)])),[[U,`dropdown-option-${Y.title}`]])]),_:1},8,["options","model-value"])),[[U,"ecommerce-tab-product-select"]])],64)):B("",!0),I.value?O((d(),S(ut,{key:1,"button-type":"outlined",class:"ecommerce-tab__edit-button",onClick:z},{default:_(()=>[j(w(A.$t("builder.editButton.ecommerce.editProduct")),1)]),_:1})),[[U,"ecommerce-settings-button-editthisproduct"]]):B("",!0)],64)):(d(),S(SI,{key:0}))])}}}),yj=H(fj,[["__scopeId","data-v-9c4b5bc2"]]),vj=q({components:{ZyroSvgDeprecated:qt},props:{modelValue:{type:String,default:""},icons:{type:Array,required:!0},theme:{type:String,validator:t=>["rounded","bordered"].includes(t),default:"bordered"},toggleable:{type:Boolean,default:!0},defaultValue:{type:String,default:""}},emits:["update:model-value"],methods:{setNewValue(t){const e=t===this.current&&this.toggleable?this.defaultValue:t;this.$emit("update:model-value",e)}}}),_j=["onClick"],wj={key:1,class:"zyro-icon-controls__value-fallback"};function kj(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated"),i=ct("qa");return d(),v("div",{class:rt(["zyro-icon-controls",`zyro-icon-controls--${t.theme}`])},[(d(!0),v(dt,null,zt(t.icons,r=>O((d(),v("div",{key:r.value,class:rt(["zyro-icon-controls__icon",{"zyro-icon-controls__icon--active":r.value===t.modelValue}]),onClick:u=>t.setNewValue(r.value)},[r.icon?(d(),S(l,{key:0,direction:r.direction,name:r.icon},null,8,["direction","name"])):(d(),v("p",wj,w(r.value),1))],10,_j)),[[i,`iconcontrols-${r.value}`]])),128))],2)}const jr=H(vj,[["render",kj],["__scopeId","data-v-29c6c8af"]]),Ij=[{value:"flex-start",icon:"align-left"},{value:"center",icon:"align-center"},{value:"flex-end",icon:"align-right"}],Sj=[{value:"flex-start",icon:"align",direction:"up"},{value:"center",icon:"align-middle"},{value:"flex-end",icon:"align",direction:"down"}],Ej=q({components:{ZyroIconControls:jr,ZyroLabel:Xt},ICONS_ALIGN:Ij,ICONS_JUSTIFY:Sj,computed:{...le(["currentElementStyles"]),align(){return this.currentElementStyles.align},justify(){return this.currentElementStyles.justify}},methods:{...be(["mergeCurrentElementData"]),updateAlign(t){this.mergeCurrentElementData({elementData:{settings:{styles:{align:t}}}})},updateJustify(t){this.mergeCurrentElementData({elementData:{settings:{styles:{justify:t}}}})}}}),xj={class:"layout"},Tj={class:"layout__alignment"};function Cj(t,e,o,n,s,a){const l=G("ZyroLabel"),i=G("ZyroIconControls");return d(),v("div",xj,[h(l,{class:"layout__alignment-label"},{default:_(()=>[j(w(t.$t("builder.editButton.tabLayoutLabel")),1)]),_:1}),m("div",Tj,[h(i,{"model-value":t.align,icons:t.$options.ICONS_ALIGN,"onUpdate:modelValue":t.updateAlign},null,8,["model-value","icons","onUpdate:modelValue"]),h(i,{"model-value":t.justify,icons:t.$options.ICONS_JUSTIFY,toggleable:!1,"onUpdate:modelValue":t.updateJustify},null,8,["model-value","icons","onUpdate:modelValue"])])])}const Pj=H(Ej,[["render",Cj],["__scopeId","data-v-e5ffffc6"]]),Bj={class:"stripe-set-up-success"},Aj={class:"text-body-1 text-bold-2"},Dj={__name:"StripeApiKeySaved",emits:["continue"],setup(t){return(e,o)=>{const n=ct("qa");return d(),v("div",Bj,[h(qt,{class:"stripe-set-up-success__icon",name:"check-circle",dimensions:"24px"}),m("p",Aj,w(e.$t("builder.editButton.stripe.setUpSuccess")),1),O((d(),S(ut,{class:"stripe-set-up-success__button",onClick:o[0]||(o[0]=s=>e.$emit("continue"))},{default:_(()=>[j(w(e.$t("builder.editButton.stripe.addProduct")),1)]),_:1})),[[n,"stripe-settings-setup-addproduct"]])])}}},zj=H(Dj,[["__scopeId","data-v-bfecb491"]]),$j=q({components:{HostingerButton:ut,ZyroFieldInput:Ge},props:{isApiKeyValid:{type:Boolean,default:!1}},emits:["save-key"],data(){return{tempApiKey:null}}}),Lj={class:"stripe-set-up__text"},Oj={class:"text-bold-1 stripe-set-up__title"},Rj=["href","textContent"];function Mj(t,e,o,n,s,a){const l=G("i18n-t"),i=G("ZyroFieldInput"),r=G("HostingerButton"),u=ct("qa");return d(),v("form",{class:"stripe-set-up",onSubmit:e[1]||(e[1]=Yt(p=>t.$emit("save-key",t.tempApiKey),["prevent"]))},[m("div",Lj,[m("p",Oj,w(t.$t("builder.editButton.stripe.setup")),1),h(l,{tag:"p",class:"text-body-1 text-body-2",keypath:"builder.editButton.stripe.activateKey"},{default:_(()=>[m("a",{class:"z-link",href:t.$t("siteSettings.integrationStripeLinkHref"),target:"_blank",textContent:w(t.$t("builder.editButton.stripe.activateKeyHow"))},null,8,Rj)]),_:1})]),h(i,{modelValue:t.tempApiKey,"onUpdate:modelValue":e[0]||(e[0]=p=>t.tempApiKey=p),class:"stripe-set-up__field","qa-selector":"stripe-settings-setup-input-apikey",placeholder:t.$t("builder.editButton.stripe.publicApiKey"),label:t.$t("builder.editButton.stripe.publicApiKey"),error:t.isApiKeyValid?null:"The publishable API key doesn't seem to be right. Please try again."},null,8,["modelValue","placeholder","label","error"]),O((d(),S(r,{class:"stripe-set-up__button",type:"submit"},{default:_(()=>[j(w(t.$t("common.save")),1)]),_:1})),[[u,"stripe-settings-setup-button-save"]])],32)}const Hj=H($j,[["render",Mj],["__scopeId","data-v-121a0b63"]]),Nj={class:"stripe-no-key"},Gj={class:"stripe-no-key__text text-body-1"},Fj={__name:"StripeNoKey",emits:["continue"],setup(t){return(e,o)=>{const n=ct("qa");return d(),v("div",Nj,[h(qt,{class:"stripe-no-key__logo",name:"stripe-blurple"}),m("p",Gj,w(e.$t("builder.editButton.stripe.acceptPayments")),1),O((d(),S(ut,{class:"stripe-no-key__button",onClick:o[0]||(o[0]=s=>e.$emit("continue"))},{default:_(()=>[j(w(e.$t("builder.editButton.stripe.setup")),1)]),_:1})),[[n,"stripe-settings-button-setupcheckout"]])])}}},Vj=H(Fj,[["__scopeId","data-v-6b5f345a"]]),Uj=q({components:{ZyroSvgDeprecated:qt},props:{type:{type:String,validator(t){return["error","success","warning","info"].includes(t)},default:"success"},message:{type:String,default:""},mode:{type:String,validator(t){return["light","dark"].includes(t)},default:"light"},icon:{type:String,default:"info-circle"},padding:{type:String,default:"18px"}},computed:{computedStyles(){return{"--notification-padding":this.padding}}}}),jj={class:"notification__wrapper"},Wj={class:"notification__message text-body-2"};function qj(t,e,o,n,s,a){const l=G("ZyroSvgDeprecated");return d(),v("div",{style:ne(t.computedStyles),class:rt(["notification",`notification--${t.mode}-${t.type}`])},[h(l,{name:t.icon,class:"notification__icon"},null,8,["name"]),m("div",jj,[m("p",Wj,[vt(t.$slots,"message",{},()=>[j(w(t.message),1)],!0)]),vt(t.$slots,"default",{},void 0,!0)])],6)}const cm=H(Uj,[["render",qj],["__scopeId","data-v-3846a491"]]),H_="addProduct",N_="noKey",G_="apiKeySet",Yj="noKeyContinue",Kj=q({components:{ZyroSelect:co,ZyroFieldInput:Ge,ZyroLabel:Xt,ZyroSegmentControl:Fi,ZyroNotification:cm,StripeApiKeySaved:zj,StripeKeySetUp:Hj,StripeNoKey:Vj},setup(){const t=Bt(),{t:e}=_t();return{PAYMENT_TYPES:[{title:e("builder.editButton.stripe.paymentPayment"),value:"payment"},{title:e("builder.editButton.stripe.paymentRecurring"),value:"subscription"}],STEP_ADD_PRODUCT:H_,STEP_NO_KEY:N_,STEP_API_KEY_SET:G_,STEP_NO_KEY_CONTINUE:Yj,siteStore:t}},data(){return{currentStep:null,isApiKeyValid:!0}},computed:{...le(["siteMeta","currentElementSettings","defaultPages"]),pages(){return Object.entries(this.defaultPages).map(([t,e])=>({id:t,path:e.slug,title:e.name||Gg(e.slug)||"Home"}))},paymentType:{get(){var o;const t=((o=this.currentElementSettings)==null?void 0:o.paymentType)||"payment";return this.PAYMENT_TYPES.find(n=>n.value===t)},set(t){this.mergeCurrentElementData({elementData:{settings:{paymentType:t.value}}})}},successPage(){const{successPageId:t}=this.currentElementSettings;return this.pages.find(({id:o})=>o===t)||Object.values(this.pages)[0]},cancellationPage(){const{cancellationPageId:t}=this.currentElementSettings;return this.pages.find(({id:o})=>o===t)||Object.values(this.pages)[0]},priceId(){var t;return((t=this.currentElementSettings)==null?void 0:t.priceId)||""},apiKey:{get(){var t;return((t=this.siteMeta)==null?void 0:t.stripePublicApiKey)||""},set(t){this.isApiKeyValid=b0.test(t),this.isApiKeyValid&&(this.currentStep=G_,this.siteStore.setSiteMetaData({key:"stripePublicApiKey",value:t}))}},isApiKeyTest(){return this.apiKey.includes("test")},isPriceIdValid(){return Y4.test(this.priceId)}},created(){this.currentStep=this.apiKey?H_:N_},methods:{...be(["mergeCurrentElementData"]),updateSuccessPage(t){this.mergeCurrentElementData({elementData:{settings:{successPageId:t.id}}})},updateCancellationPage(t){this.mergeCurrentElementData({elementData:{settings:{cancellationPageId:t.id}}})},updatePriceId(t){this.mergeCurrentElementData({elementData:{settings:{priceId:t}}})}}}),Zj={class:"stripe-product"},Qj=["href"],Xj=["href"],Jj=["href"],tW={class:"text-body-2 setting-description"},eW={class:"text-body-2 setting-description"};function oW(t,e,o,n,s,a){const l=G("StripeNoKey"),i=G("StripeKeySetUp"),r=G("StripeApiKeySaved"),u=G("ZyroNotification"),p=G("ZyroFieldInput"),g=G("ZyroLabel"),b=G("ZyroSegmentControl"),y=G("ZyroSelect"),k=ct("qa");return d(),v("div",Zj,[t.currentStep===t.STEP_NO_KEY?(d(),S(l,{key:0,onContinue:e[0]||(e[0]=I=>t.currentStep=t.STEP_NO_KEY_CONTINUE)})):B("",!0),t.currentStep===t.STEP_NO_KEY_CONTINUE?(d(),S(i,{key:1,"is-api-key-valid":t.isApiKeyValid,onSaveKey:e[1]||(e[1]=I=>t.apiKey=I)},null,8,["is-api-key-valid"])):t.currentStep===t.STEP_API_KEY_SET?(d(),S(r,{key:2,onContinue:e[2]||(e[2]=I=>t.currentStep=t.STEP_ADD_PRODUCT)})):t.currentStep===t.STEP_ADD_PRODUCT?(d(),v(dt,{key:3},[m("a",{href:t.$t("siteSettings.integrationStripeLinkHref"),target:"_blank",class:"stripe-product__link"},[h(u,{class:"stripe-product__notification",message:t.isApiKeyTest?t.$t("builder.editButton.stripe.usingTestKey"):t.$t("builder.editButton.stripe.usingLiveKey"),type:t.isApiKeyTest?"warning":"info",padding:"8px 14px"},null,8,["message","type"])],8,Qj),h(p,{"model-value":t.priceId,"qa-selector":"stripe-settings-input-priceid",class:"stripe-product__price-id-field",placeholder:t.$t("builder.editButton.stripe.priceId"),error:!t.isPriceIdValid&&t.priceId.length>0,label:t.$t("builder.editButton.stripe.priceId"),"onUpdate:modelValue":t.updatePriceId},{error:_(()=>[j(w(t.$t("builder.editButton.stripe.priceIdIncorrect"))+" ",1),m("a",{class:"stripe-product__notification--error-link",href:t.$t("siteSettings.integrationStripeLinkHref")},w(t.$t("builder.editButton.stripe.findPriceId")),9,Xj)]),_:1},8,["model-value","placeholder","error","label","onUpdate:modelValue"]),t.isPriceIdValid||t.priceId.length===0?(d(),v("a",{key:0,class:"text-body-2 z-link setting-description",href:t.$t("siteSettings.integrationStripeLinkHref"),target:"_blank"},w(t.$t("builder.editButton.stripe.findPriceId")),9,Jj)):B("",!0),h(g,{class:"label"},{default:_(()=>[j(w(t.$t("builder.editButton.stripe.paymentType")),1)]),_:1}),h(b,{class:"segment-control",controls:t.PAYMENT_TYPES,"active-control":t.paymentType,"onUpdate:activeControl":e[3]||(e[3]=I=>t.paymentType=I)},null,8,["controls","active-control"]),h(g,{class:"label"},{default:_(()=>[j(w(t.$t("builder.editButton.stripe.successPage")),1)]),_:1}),O(h(y,{class:"page-dropdown","label-key":"title",options:t.pages,"model-value":t.successPage,"onUpdate:modelValue":t.updateSuccessPage},null,8,["options","model-value","onUpdate:modelValue"]),[[k,"stripe-success-page-select"]]),m("p",tW,w(t.$t("builder.editButton.stripe.successPageDescription")),1),h(g,{class:"label"},{default:_(()=>[j(w(t.$t("builder.editButton.stripe.cancellationPage")),1)]),_:1}),O(h(y,{class:"page-dropdown","label-key":"title",options:t.pages,"model-value":t.cancellationPage,"onUpdate:modelValue":t.updateCancellationPage},null,8,["options","model-value","onUpdate:modelValue"]),[[k,"stripe-cancel-page-select"]]),m("p",eW,w(t.$t("builder.editButton.stripe.cancelPageDescription")),1)],64)):B("",!0)])}const nW=H(Kj,[["render",oW],["__scopeId","data-v-ffcaca25"]]),iW=Hx.extend({parseHTML(){return[{tag:"strong"},{tag:"b",getAttrs:t=>t.style.fontWeight!=="normal"&&null}]}}),F_="--fontSizeMobile",V_="--fontSizeDesktop",sW=fl.create({name:"fontSize",addOptions(){return{types:[pn,Xo,"textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontSizeMobile:{parseHTML:t=>t.style.getPropertyValue(F_).replace(/["']+/g,""),renderHTML:t=>t.fontSizeMobile?{style:`${F_}: ${t.fontSizeMobile}`}:{}},fontSizeDesktop:{parseHTML:t=>t.style.getPropertyValue(V_).replace(/["']+/g,""),renderHTML:t=>t.fontSizeDesktop?{style:`${V_}: ${t.fontSizeDesktop}`}:{}}}}]},addCommands(){return{setMarkFontSize:(t,e)=>({chain:o})=>{const n=e?{fontSizeMobile:t}:{fontSizeDesktop:t};return o().setMark("textStyle",n).run()},unsetMarkFontSize:()=>({chain:t})=>t().setMark("textStyle",{fontSizeMobile:null,fontSizeDesktop:null}).removeEmptyTextStyle().run()}}}),aW=fl.create({name:"fontWeight",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontWeight:{default:null,parseHTML:t=>t.style.fontWeight.replace(/["']+/g,""),renderHTML:t=>t.fontWeight?{style:`font-weight: ${t.fontWeight}`}:{}}}}]},addCommands(){return{setFontWeight:t=>({chain:e})=>e().setMark("textStyle",{fontWeight:t}).run(),unsetFontWeight:()=>({chain:t})=>t().setMark("textStyle",{fontWeight:null}).removeEmptyTextStyle().run()}}}),lW=fl.create({name:k1,addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{[k1]:{default:null,renderHTML:t=>t.letterCase?{style:`text-transform: ${t.letterCase}`}:{},parseHTML:t=>t.style.textTransform.replace(/["']+/g,"")}}}]},addCommands(){return{toggleLetterCase:t=>({commands:e})=>e.toggleMark("textStyle",{letterCase:t})}}}),rW=fl.create({name:"letterSpacing",addOptions(){return{types:["textStyle","heading","paragraph"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{letterSpacing:{default:null,parseHTML:t=>t.style.letterSpacing.replace(/["']+/g,""),renderHTML:t=>t.letterSpacing?{style:`letter-spacing: ${t.letterSpacing}`}:{}}}}]},addCommands(){return{setMarkLetterSpacing:t=>({chain:e})=>e().setMark("textStyle",{letterSpacing:t}).run(),unsetMarkLetterSpacing:()=>({chain:t})=>t().setMark("textStyle",{letterSpacing:null}).removeEmptyTextStyle().run()}}}),dW=Kv.extend({addOptions(){return{...Kv.options,openOnClick:!1,autolink:!1}},priority:99,addAttributes(){var t;return{...(t=this.parent)==null?void 0:t.call(this),rel:{default:null},title:{default:null},download:{default:null},style:{default:null},target:{default:null},[h0]:{default:null}}}}),cW=Nx.extend({addOptions(){return{types:[pn,Xo,Nb,Hp]}}}),uW=Zv.extend({addOptions(){return{...Zv.options,levels:m0}},addKeyboardShortcuts(){return[]},addInputRules(){return[]}}),U_="--lineHeightMobile",j_="--lineHeightDesktop",pW=fl.create({name:"lineHeight",addOptions(){return{types:[pn,Xo]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{lineHeightMobile:{parseHTML:t=>t.style.getPropertyValue(U_).replace(/["']+/g,""),renderHTML:t=>t.lineHeightMobile?{style:`${U_}: ${t.lineHeightMobile}`}:{}},lineHeightDesktop:{parseHTML:t=>t.style.getPropertyValue(j_).replace(/["']+/g,""),renderHTML:t=>t.lineHeightDesktop?{style:`${j_}: ${t.lineHeightDesktop}`}:{}}}}]},addCommands(){return{setLineHeight:(t,e)=>({chain:o})=>{const n=e?{lineHeightMobile:t}:{lineHeightDesktop:t};return o().setMark("textStyle",n).run()}}}}),gW=Gx.extend({content:"(paragraph|heading) block*"}),mW=fl.create({name:"marginBottom",addOptions(){return{types:[pn,Xo]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{marginBottom:{default:null,parseHTML:t=>t.style.marginBottom.replace(/["']+/g,""),renderHTML:t=>t.marginBottom?{style:`margin-bottom: ${t.marginBottom}`}:{}}}}]}}),hW=Fx.extend({name:Xo,addAttributes(){return{className:{default:Jd,parseHTML:t=>t.getAttribute("class"),renderHTML:t=>!t.className||!XP.includes(t.className)?{class:Jd}:{class:t.className}}}},addCommands(){return{setParagraph:t=>({commands:e})=>e.setNode(Xo,t)}}}),bW=fl.create({name:"AutoDir",addGlobalAttributes(){return[{types:["heading","paragraph","bulletList","orderedList","blockquote"],attributes:{autoDir:{renderHTML:()=>({dir:"auto"}),parseHTML:t=>t.dir||"auto"}}}]}}),fW=()=>t=>{_s(t,"element",e=>{var p;if(!((p=e.properties)!=null&&p.style))return;const{width:o,"max-width":n,"min-width":s,height:a,"max-height":l,"min-height":i,...r}=T5(e.properties.style)||{},u=Object.entries(r).map(([g,b])=>`${g}: ${b}`).join("; ");e.properties.style=u})},yW=t=>t.replace(/\\+/g,"").replace(/"/g,""),vW=()=>t=>_s(t,"element",e=>{var o;(o=e.properties)!=null&&o.style&&(e.properties.style=yW(e.properties.style))}),_W={useBuiltInExtensions:!1,editorProps:{transformPastedText(t){return t.replace(/\u00A0/g," ")},transformPastedHTML(t){return vs().data("settings",ws).use(fW).use(vW).processSync(t).toString().replace(/\u00A0/g," ")}},parseOptions:{preserveWhitespace:!0},extensions:[bW,Ux,jx,uW,hW,Wx,qx,cW,iW,Yx,Kx,Zx,Qx,Xx,gW,dW,pW,Jx,lW,rW,sW,tT,aW,mW]},Ii=C(void 0),wi=()=>{const t=l=>{Ii.value=new Vx({..._W,content:l})},e=()=>{Ii.value=void 0},o=c(()=>{var p,g,b;if(!((b=(g=(p=Ii.value)==null?void 0:p.view)==null?void 0:g.state)!=null&&b.selection))return!1;const{$anchor:l,$head:i}=Ii.value.view.state.selection,r=l.parentOffset===0&&i.parentOffset===i.parent.content.size,u=i.parentOffset===0&&l.parentOffset===l.parent.content.size;return r||u});return{editor:Ii,initializeEditor:t,removeEditor:e,setCaretPositionToEnd:()=>{var l;(l=Ii.value)==null||l.commands.focus("end")},insertHTMLToEnd:l=>{var i;(i=Ii.value)==null||i.commands.setContent(`${Ii.value.getHTML()}${l}`)},isAllTextNodeSelected:o,getInlineStyleValue:l=>Ii.value&&(Ii.value.getAttributes("textStyle")[l]||Ii.value.getAttributes(Xo)[l]||Ii.value.getAttributes(pn)[l])||null}},wW="webfonts#webfontList",kW=[{family:"Roboto",variants:["100","100italic","300","300italic","regular","italic","500","500italic","700","700italic","900","900italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v29",lastModified:"2021-09-22",files:{100:"http://fonts.gstatic.com/s/roboto/v29/KFOkCnqEu92Fr1MmgWxPKTM1K9nz.ttf",300:"http://fonts.gstatic.com/s/roboto/v29/KFOlCnqEu92Fr1MmSU5vAx05IsDqlA.ttf",500:"http://fonts.gstatic.com/s/roboto/v29/KFOlCnqEu92Fr1MmEU9vAx05IsDqlA.ttf",700:"http://fonts.gstatic.com/s/roboto/v29/KFOlCnqEu92Fr1MmWUlvAx05IsDqlA.ttf",900:"http://fonts.gstatic.com/s/roboto/v29/KFOlCnqEu92Fr1MmYUtvAx05IsDqlA.ttf","100italic":"http://fonts.gstatic.com/s/roboto/v29/KFOiCnqEu92Fr1Mu51QrIzcXLsnzjYk.ttf","300italic":"http://fonts.gstatic.com/s/roboto/v29/KFOjCnqEu92Fr1Mu51TjARc9AMX6lJBP.ttf",regular:"http://fonts.gstatic.com/s/roboto/v29/KFOmCnqEu92Fr1Me5WZLCzYlKw.ttf",italic:"http://fonts.gstatic.com/s/roboto/v29/KFOkCnqEu92Fr1Mu52xPKTM1K9nz.ttf","500italic":"http://fonts.gstatic.com/s/roboto/v29/KFOjCnqEu92Fr1Mu51S7ABc9AMX6lJBP.ttf","700italic":"http://fonts.gstatic.com/s/roboto/v29/KFOjCnqEu92Fr1Mu51TzBhc9AMX6lJBP.ttf","900italic":"http://fonts.gstatic.com/s/roboto/v29/KFOjCnqEu92Fr1Mu51TLBBc9AMX6lJBP.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Open Sans",variants:["300","regular","500","600","700","800","300italic","italic","500italic","600italic","700italic","800italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","latin","latin-ext","vietnamese"],version:"v27",lastModified:"2021-10-28",files:{300:"http://fonts.gstatic.com/s/opensans/v27/memSYaGs126MiZpBA-UvWbX2vVnXBbObj2OVZyOOSr4dVJWUgsiH0C4nY1M2xLER.ttf",500:"http://fonts.gstatic.com/s/opensans/v27/memSYaGs126MiZpBA-UvWbX2vVnXBbObj2OVZyOOSr4dVJWUgsjr0C4nY1M2xLER.ttf",600:"http://fonts.gstatic.com/s/opensans/v27/memSYaGs126MiZpBA-UvWbX2vVnXBbObj2OVZyOOSr4dVJWUgsgH1y4nY1M2xLER.ttf",700:"http://fonts.gstatic.com/s/opensans/v27/memSYaGs126MiZpBA-UvWbX2vVnXBbObj2OVZyOOSr4dVJWUgsg-1y4nY1M2xLER.ttf",800:"http://fonts.gstatic.com/s/opensans/v27/memSYaGs126MiZpBA-UvWbX2vVnXBbObj2OVZyOOSr4dVJWUgshZ1y4nY1M2xLER.ttf",regular:"http://fonts.gstatic.com/s/opensans/v27/memSYaGs126MiZpBA-UvWbX2vVnXBbObj2OVZyOOSr4dVJWUgsjZ0C4nY1M2xLER.ttf","300italic":"http://fonts.gstatic.com/s/opensans/v27/memQYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWq8tWZ0Pw86hd0Rk5hkaVcUwaERZjA.ttf",italic:"http://fonts.gstatic.com/s/opensans/v27/memQYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWq8tWZ0Pw86hd0Rk8ZkaVcUwaERZjA.ttf","500italic":"http://fonts.gstatic.com/s/opensans/v27/memQYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWq8tWZ0Pw86hd0Rk_RkaVcUwaERZjA.ttf","600italic":"http://fonts.gstatic.com/s/opensans/v27/memQYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWq8tWZ0Pw86hd0RkxhjaVcUwaERZjA.ttf","700italic":"http://fonts.gstatic.com/s/opensans/v27/memQYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWq8tWZ0Pw86hd0RkyFjaVcUwaERZjA.ttf","800italic":"http://fonts.gstatic.com/s/opensans/v27/memQYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWq8tWZ0Pw86hd0Rk0ZjaVcUwaERZjA.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Noto Sans JP",variants:["100","300","regular","500","700","900"],subsets:["japanese","latin"],version:"v40",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/notosansjp/v40/-F6ofjtqLzI2JPCgQBnw7HFQoggM-FNthvIU.otf",300:"http://fonts.gstatic.com/s/notosansjp/v40/-F6pfjtqLzI2JPCgQBnw7HFQaioq1H1hj-sNFQ.otf",500:"http://fonts.gstatic.com/s/notosansjp/v40/-F6pfjtqLzI2JPCgQBnw7HFQMisq1H1hj-sNFQ.otf",700:"http://fonts.gstatic.com/s/notosansjp/v40/-F6pfjtqLzI2JPCgQBnw7HFQei0q1H1hj-sNFQ.otf",900:"http://fonts.gstatic.com/s/notosansjp/v40/-F6pfjtqLzI2JPCgQBnw7HFQQi8q1H1hj-sNFQ.otf",regular:"http://fonts.gstatic.com/s/notosansjp/v40/-F62fjtqLzI2JPCgQBnw7HFowAIO2lZ9hg.otf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Lato",variants:["100","100italic","300","300italic","regular","italic","700","700italic","900","900italic"],subsets:["latin","latin-ext"],version:"v22",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/lato/v22/S6u8w4BMUTPHh30wWyWrFCbw7A.ttf",300:"http://fonts.gstatic.com/s/lato/v22/S6u9w4BMUTPHh7USew-FGC_p9dw.ttf",700:"http://fonts.gstatic.com/s/lato/v22/S6u9w4BMUTPHh6UVew-FGC_p9dw.ttf",900:"http://fonts.gstatic.com/s/lato/v22/S6u9w4BMUTPHh50Xew-FGC_p9dw.ttf","100italic":"http://fonts.gstatic.com/s/lato/v22/S6u-w4BMUTPHjxsIPy-vNiPg7MU0.ttf","300italic":"http://fonts.gstatic.com/s/lato/v22/S6u_w4BMUTPHjxsI9w2PHA3s5dwt7w.ttf",regular:"http://fonts.gstatic.com/s/lato/v22/S6uyw4BMUTPHvxk6XweuBCY.ttf",italic:"http://fonts.gstatic.com/s/lato/v22/S6u8w4BMUTPHjxswWyWrFCbw7A.ttf","700italic":"http://fonts.gstatic.com/s/lato/v22/S6u_w4BMUTPHjxsI5wqPHA3s5dwt7w.ttf","900italic":"http://fonts.gstatic.com/s/lato/v22/S6u_w4BMUTPHjxsI3wiPHA3s5dwt7w.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Montserrat",variants:["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v23",lastModified:"2022-02-03",files:{100:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCtr6Uw-Y3tcoqK5.ttf",200:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCvr6Ew-Y3tcoqK5.ttf",300:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCs16Ew-Y3tcoqK5.ttf",500:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCtZ6Ew-Y3tcoqK5.ttf",600:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCu170w-Y3tcoqK5.ttf",700:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCuM70w-Y3tcoqK5.ttf",800:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCvr70w-Y3tcoqK5.ttf",900:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCvC70w-Y3tcoqK5.ttf",regular:"http://fonts.gstatic.com/s/montserrat/v23/JTUHjIg1_i6t8kCHKm4532VJOt5-QNFgpCtr6Ew-Y3tcoqK5.ttf","100italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jq6R8aX9-p7K5ILg.ttf","200italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jqyR9aX9-p7K5ILg.ttf","300italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jq_p9aX9-p7K5ILg.ttf",italic:"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jq6R9aX9-p7K5ILg.ttf","500italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jq5Z9aX9-p7K5ILg.ttf","600italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jq3p6aX9-p7K5ILg.ttf","700italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jq0N6aX9-p7K5ILg.ttf","800italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jqyR6aX9-p7K5ILg.ttf","900italic":"http://fonts.gstatic.com/s/montserrat/v23/JTUFjIg1_i6t8kCHKm459Wx7xQYXK0vOoz6jqw16aX9-p7K5ILg.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Poppins",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],subsets:["devanagari","latin","latin-ext"],version:"v19",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/poppins/v19/pxiGyp8kv8JHgFVrLPTed3FBGPaTSQ.ttf",200:"http://fonts.gstatic.com/s/poppins/v19/pxiByp8kv8JHgFVrLFj_V1tvFP-KUEg.ttf",300:"http://fonts.gstatic.com/s/poppins/v19/pxiByp8kv8JHgFVrLDz8V1tvFP-KUEg.ttf",500:"http://fonts.gstatic.com/s/poppins/v19/pxiByp8kv8JHgFVrLGT9V1tvFP-KUEg.ttf",600:"http://fonts.gstatic.com/s/poppins/v19/pxiByp8kv8JHgFVrLEj6V1tvFP-KUEg.ttf",700:"http://fonts.gstatic.com/s/poppins/v19/pxiByp8kv8JHgFVrLCz7V1tvFP-KUEg.ttf",800:"http://fonts.gstatic.com/s/poppins/v19/pxiByp8kv8JHgFVrLDD4V1tvFP-KUEg.ttf",900:"http://fonts.gstatic.com/s/poppins/v19/pxiByp8kv8JHgFVrLBT5V1tvFP-KUEg.ttf","100italic":"http://fonts.gstatic.com/s/poppins/v19/pxiAyp8kv8JHgFVrJJLmE3tFOvODSVFF.ttf","200italic":"http://fonts.gstatic.com/s/poppins/v19/pxiDyp8kv8JHgFVrJJLmv1plEN2PQEhcqw.ttf","300italic":"http://fonts.gstatic.com/s/poppins/v19/pxiDyp8kv8JHgFVrJJLm21llEN2PQEhcqw.ttf",regular:"http://fonts.gstatic.com/s/poppins/v19/pxiEyp8kv8JHgFVrFJDUc1NECPY.ttf",italic:"http://fonts.gstatic.com/s/poppins/v19/pxiGyp8kv8JHgFVrJJLed3FBGPaTSQ.ttf","500italic":"http://fonts.gstatic.com/s/poppins/v19/pxiDyp8kv8JHgFVrJJLmg1hlEN2PQEhcqw.ttf","600italic":"http://fonts.gstatic.com/s/poppins/v19/pxiDyp8kv8JHgFVrJJLmr19lEN2PQEhcqw.ttf","700italic":"http://fonts.gstatic.com/s/poppins/v19/pxiDyp8kv8JHgFVrJJLmy15lEN2PQEhcqw.ttf","800italic":"http://fonts.gstatic.com/s/poppins/v19/pxiDyp8kv8JHgFVrJJLm111lEN2PQEhcqw.ttf","900italic":"http://fonts.gstatic.com/s/poppins/v19/pxiDyp8kv8JHgFVrJJLm81xlEN2PQEhcqw.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Roboto Condensed",variants:["300","300italic","regular","italic","700","700italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v24",lastModified:"2022-01-27",files:{300:"http://fonts.gstatic.com/s/robotocondensed/v24/ieVi2ZhZI2eCN5jzbjEETS9weq8-33mZKCMSbvtdYyQ.ttf",700:"http://fonts.gstatic.com/s/robotocondensed/v24/ieVi2ZhZI2eCN5jzbjEETS9weq8-32meKCMSbvtdYyQ.ttf","300italic":"http://fonts.gstatic.com/s/robotocondensed/v24/ieVg2ZhZI2eCN5jzbjEETS9weq8-19eDpCEYatlYcyRi4A.ttf",regular:"http://fonts.gstatic.com/s/robotocondensed/v24/ieVl2ZhZI2eCN5jzbjEETS9weq8-59WxDCs5cvI.ttf",italic:"http://fonts.gstatic.com/s/robotocondensed/v24/ieVj2ZhZI2eCN5jzbjEETS9weq8-19e7CAk8YvJEeg.ttf","700italic":"http://fonts.gstatic.com/s/robotocondensed/v24/ieVg2ZhZI2eCN5jzbjEETS9weq8-19eDtCYYatlYcyRi4A.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Oswald",variants:["200","300","regular","500","600","700"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v41",lastModified:"2022-02-03",files:{200:"http://fonts.gstatic.com/s/oswald/v41/TK3_WkUHHAIjg75cFRf3bXL8LICs13FvgUFoZAaRliE.ttf",300:"http://fonts.gstatic.com/s/oswald/v41/TK3_WkUHHAIjg75cFRf3bXL8LICs169vgUFoZAaRliE.ttf",500:"http://fonts.gstatic.com/s/oswald/v41/TK3_WkUHHAIjg75cFRf3bXL8LICs18NvgUFoZAaRliE.ttf",600:"http://fonts.gstatic.com/s/oswald/v41/TK3_WkUHHAIjg75cFRf3bXL8LICs1y9ogUFoZAaRliE.ttf",700:"http://fonts.gstatic.com/s/oswald/v41/TK3_WkUHHAIjg75cFRf3bXL8LICs1xZogUFoZAaRliE.ttf",regular:"http://fonts.gstatic.com/s/oswald/v41/TK3_WkUHHAIjg75cFRf3bXL8LICs1_FvgUFoZAaRliE.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Roboto Mono",variants:["100","200","300","regular","500","600","700","100italic","200italic","300italic","italic","500italic","600italic","700italic"],subsets:["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],version:"v13",lastModified:"2021-01-30",files:{100:"http://fonts.gstatic.com/s/robotomono/v13/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vuPQ--5Ip2sSQ.ttf",200:"http://fonts.gstatic.com/s/robotomono/v13/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_XvqPQ--5Ip2sSQ.ttf",300:"http://fonts.gstatic.com/s/robotomono/v13/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_gPqPQ--5Ip2sSQ.ttf",500:"http://fonts.gstatic.com/s/robotomono/v13/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_7PqPQ--5Ip2sSQ.ttf",600:"http://fonts.gstatic.com/s/robotomono/v13/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_AP2PQ--5Ip2sSQ.ttf",700:"http://fonts.gstatic.com/s/robotomono/v13/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_Of2PQ--5Ip2sSQ.ttf",regular:"http://fonts.gstatic.com/s/robotomono/v13/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vqPQ--5Ip2sSQ.ttf","100italic":"http://fonts.gstatic.com/s/robotomono/v13/L0xoDF4xlVMF-BfR8bXMIjhOsXG-q2oeuFoqFrlnAeW9AJi8SZwt.ttf","200italic":"http://fonts.gstatic.com/s/robotomono/v13/L0xoDF4xlVMF-BfR8bXMIjhOsXG-q2oeuFoqFrnnAOW9AJi8SZwt.ttf","300italic":"http://fonts.gstatic.com/s/robotomono/v13/L0xoDF4xlVMF-BfR8bXMIjhOsXG-q2oeuFoqFrk5AOW9AJi8SZwt.ttf",italic:"http://fonts.gstatic.com/s/robotomono/v13/L0xoDF4xlVMF-BfR8bXMIjhOsXG-q2oeuFoqFrlnAOW9AJi8SZwt.ttf","500italic":"http://fonts.gstatic.com/s/robotomono/v13/L0xoDF4xlVMF-BfR8bXMIjhOsXG-q2oeuFoqFrlVAOW9AJi8SZwt.ttf","600italic":"http://fonts.gstatic.com/s/robotomono/v13/L0xoDF4xlVMF-BfR8bXMIjhOsXG-q2oeuFoqFrm5B-W9AJi8SZwt.ttf","700italic":"http://fonts.gstatic.com/s/robotomono/v13/L0xoDF4xlVMF-BfR8bXMIjhOsXG-q2oeuFoqFrmAB-W9AJi8SZwt.ttf"},category:"monospace",kind:"webfonts#webfont"},{family:"Noto Sans",variants:["regular","italic","700","700italic"],subsets:["cyrillic","cyrillic-ext","devanagari","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v25",lastModified:"2022-01-27",files:{700:"http://fonts.gstatic.com/s/notosans/v25/o-0NIpQlx3QUlC5A4PNjXhFlY9aA5Wl6PQ.ttf",regular:"http://fonts.gstatic.com/s/notosans/v25/o-0IIpQlx3QUlC5A4PNb4j5Ba_2c7A.ttf",italic:"http://fonts.gstatic.com/s/notosans/v25/o-0OIpQlx3QUlC5A4PNr4DRFSfiM7HBj.ttf","700italic":"http://fonts.gstatic.com/s/notosans/v25/o-0TIpQlx3QUlC5A4PNr4Az5ZtyEx2xqPaif.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Raleway",variants:["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v26",lastModified:"2022-02-03",files:{100:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVvao4CPNLA3JC9c.ttf",200:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVtaooCPNLA3JC9c.ttf",300:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVuEooCPNLA3JC9c.ttf",500:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVvoooCPNLA3JC9c.ttf",600:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVsEpYCPNLA3JC9c.ttf",700:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVs9pYCPNLA3JC9c.ttf",800:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVtapYCPNLA3JC9c.ttf",900:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVtzpYCPNLA3JC9c.ttf",regular:"http://fonts.gstatic.com/s/raleway/v26/1Ptxg8zYS_SKggPN4iEgvnHyvveLxVvaooCPNLA3JC9c.ttf","100italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4WjNPrQVIT9c2c8.ttf","200italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4ejMPrQVIT9c2c8.ttf","300italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4TbMPrQVIT9c2c8.ttf",italic:"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4WjMPrQVIT9c2c8.ttf","500italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4VrMPrQVIT9c2c8.ttf","600italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4bbLPrQVIT9c2c8.ttf","700italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4Y_LPrQVIT9c2c8.ttf","800italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4ejLPrQVIT9c2c8.ttf","900italic":"http://fonts.gstatic.com/s/raleway/v26/1Pt_g8zYS_SKggPNyCgSQamb1W0lwk4S4cHLPrQVIT9c2c8.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Ubuntu",variants:["300","300italic","regular","italic","500","500italic","700","700italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext"],version:"v19",lastModified:"2022-01-27",files:{300:"http://fonts.gstatic.com/s/ubuntu/v19/4iCv6KVjbNBYlgoC1CzTt2aMH4V_gg.ttf",500:"http://fonts.gstatic.com/s/ubuntu/v19/4iCv6KVjbNBYlgoCjC3Tt2aMH4V_gg.ttf",700:"http://fonts.gstatic.com/s/ubuntu/v19/4iCv6KVjbNBYlgoCxCvTt2aMH4V_gg.ttf","300italic":"http://fonts.gstatic.com/s/ubuntu/v19/4iCp6KVjbNBYlgoKejZftWyIPYBvgpUI.ttf",regular:"http://fonts.gstatic.com/s/ubuntu/v19/4iCs6KVjbNBYlgo6eAT3v02QFg.ttf",italic:"http://fonts.gstatic.com/s/ubuntu/v19/4iCu6KVjbNBYlgoKeg7znUiAFpxm.ttf","500italic":"http://fonts.gstatic.com/s/ubuntu/v19/4iCp6KVjbNBYlgoKejYHtGyIPYBvgpUI.ttf","700italic":"http://fonts.gstatic.com/s/ubuntu/v19/4iCp6KVjbNBYlgoKejZPsmyIPYBvgpUI.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Nunito",variants:["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v22",lastModified:"2022-02-03",files:{200:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDDshRTM9jo7eTWk.ttf",300:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDOUhRTM9jo7eTWk.ttf",500:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDIkhRTM9jo7eTWk.ttf",600:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDGUmRTM9jo7eTWk.ttf",700:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDFwmRTM9jo7eTWk.ttf",800:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDDsmRTM9jo7eTWk.ttf",900:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDBImRTM9jo7eTWk.ttf",regular:"http://fonts.gstatic.com/s/nunito/v22/XRXI3I6Li01BKofiOc5wtlZ2di8HDLshRTM9jo7eTWk.ttf","200italic":"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNiLXA3iqzbXWnoeg.ttf","300italic":"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNi83A3iqzbXWnoeg.ttf",italic:"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNirXA3iqzbXWnoeg.ttf","500italic":"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNin3A3iqzbXWnoeg.ttf","600italic":"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNic3c3iqzbXWnoeg.ttf","700italic":"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNiSnc3iqzbXWnoeg.ttf","800italic":"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNiLXc3iqzbXWnoeg.ttf","900italic":"http://fonts.gstatic.com/s/nunito/v22/XRXK3I6Li01BKofIMPyPbj8d7IEAGXNiBHc3iqzbXWnoeg.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"PT Sans",variants:["regular","italic","700","700italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext"],version:"v16",lastModified:"2022-01-27",files:{700:"http://fonts.gstatic.com/s/ptsans/v16/jizfRExUiTo99u79B_mh4OmnLD0Z4zM.ttf",regular:"http://fonts.gstatic.com/s/ptsans/v16/jizaRExUiTo99u79P0WOxOGMMDQ.ttf",italic:"http://fonts.gstatic.com/s/ptsans/v16/jizYRExUiTo99u79D0eEwMOJIDQA-g.ttf","700italic":"http://fonts.gstatic.com/s/ptsans/v16/jizdRExUiTo99u79D0e8fOytKB8c8zMrig.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Roboto Slab",variants:["100","200","300","regular","500","600","700","800","900"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v22",lastModified:"2022-02-03",files:{100:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjojIWWaG5iddG-1A.ttf",200:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjoDISWaG5iddG-1A.ttf",300:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjo0oSWaG5iddG-1A.ttf",500:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjovoSWaG5iddG-1A.ttf",600:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjoUoOWaG5iddG-1A.ttf",700:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjoa4OWaG5iddG-1A.ttf",800:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjoDIOWaG5iddG-1A.ttf",900:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjoJYOWaG5iddG-1A.ttf",regular:"http://fonts.gstatic.com/s/robotoslab/v22/BngbUXZYTXPIvIBgJJSb6s3BzlRRfKOFbvjojISWaG5iddG-1A.ttf"},category:"serif",kind:"webfonts#webfont"},{family:"Merriweather",variants:["300","300italic","regular","italic","700","700italic","900","900italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v28",lastModified:"2021-12-17",files:{300:"http://fonts.gstatic.com/s/merriweather/v28/u-4n0qyriQwlOrhSvowK_l521wRpX837pvjxPA.ttf",700:"http://fonts.gstatic.com/s/merriweather/v28/u-4n0qyriQwlOrhSvowK_l52xwNpX837pvjxPA.ttf",900:"http://fonts.gstatic.com/s/merriweather/v28/u-4n0qyriQwlOrhSvowK_l52_wFpX837pvjxPA.ttf","300italic":"http://fonts.gstatic.com/s/merriweather/v28/u-4l0qyriQwlOrhSvowK_l5-eR7lXcf_hP3hPGWH.ttf",regular:"http://fonts.gstatic.com/s/merriweather/v28/u-440qyriQwlOrhSvowK_l5OeyxNV-bnrw.ttf",italic:"http://fonts.gstatic.com/s/merriweather/v28/u-4m0qyriQwlOrhSvowK_l5-eSZJdeP3r-Ho.ttf","700italic":"http://fonts.gstatic.com/s/merriweather/v28/u-4l0qyriQwlOrhSvowK_l5-eR71Wsf_hP3hPGWH.ttf","900italic":"http://fonts.gstatic.com/s/merriweather/v28/u-4l0qyriQwlOrhSvowK_l5-eR7NWMf_hP3hPGWH.ttf"},category:"serif",kind:"webfonts#webfont"},{family:"Playfair Display",variants:["regular","500","600","700","800","900","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["cyrillic","latin","latin-ext","vietnamese"],version:"v28",lastModified:"2022-02-03",files:{500:"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFvD-vYSZviVYUb_rj3ij__anPXJzDwcbmjWBN2PKd3vUDQZNLo_U2r.ttf",600:"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFvD-vYSZviVYUb_rj3ij__anPXJzDwcbmjWBN2PKebukDQZNLo_U2r.ttf",700:"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFvD-vYSZviVYUb_rj3ij__anPXJzDwcbmjWBN2PKeiukDQZNLo_U2r.ttf",800:"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFvD-vYSZviVYUb_rj3ij__anPXJzDwcbmjWBN2PKfFukDQZNLo_U2r.ttf",900:"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFvD-vYSZviVYUb_rj3ij__anPXJzDwcbmjWBN2PKfsukDQZNLo_U2r.ttf",regular:"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFvD-vYSZviVYUb_rj3ij__anPXJzDwcbmjWBN2PKdFvUDQZNLo_U2r.ttf",italic:"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFRD-vYSZviVYUb_rj3ij__anPXDTnCjmHKM4nYO7KN_qiTbtbK-F2rA0s.ttf","500italic":"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFRD-vYSZviVYUb_rj3ij__anPXDTnCjmHKM4nYO7KN_pqTbtbK-F2rA0s.ttf","600italic":"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFRD-vYSZviVYUb_rj3ij__anPXDTnCjmHKM4nYO7KN_naUbtbK-F2rA0s.ttf","700italic":"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFRD-vYSZviVYUb_rj3ij__anPXDTnCjmHKM4nYO7KN_k-UbtbK-F2rA0s.ttf","800italic":"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFRD-vYSZviVYUb_rj3ij__anPXDTnCjmHKM4nYO7KN_iiUbtbK-F2rA0s.ttf","900italic":"http://fonts.gstatic.com/s/playfairdisplay/v28/nuFRD-vYSZviVYUb_rj3ij__anPXDTnCjmHKM4nYO7KN_gGUbtbK-F2rA0s.ttf"},category:"serif",kind:"webfonts#webfont"},{family:"Inter",variants:["100","200","300","regular","500","600","700","800","900"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v7",lastModified:"2021-11-10",files:{100:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuLyeMZhrib2Bg-4.ttf",200:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuDyfMZhrib2Bg-4.ttf",300:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuOKfMZhrib2Bg-4.ttf",500:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuI6fMZhrib2Bg-4.ttf",600:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuGKYMZhrib2Bg-4.ttf",700:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuFuYMZhrib2Bg-4.ttf",800:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuDyYMZhrib2Bg-4.ttf",900:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuBWYMZhrib2Bg-4.ttf",regular:"http://fonts.gstatic.com/s/inter/v7/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuLyfMZhrib2Bg-4.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Noto Sans KR",variants:["100","300","regular","500","700","900"],subsets:["korean","latin"],version:"v25",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/notosanskr/v25/Pby6FmXiEBPT4ITbgNA5CgmOsn7uwpYcuH8y.otf",300:"http://fonts.gstatic.com/s/notosanskr/v25/Pby7FmXiEBPT4ITbgNA5CgmOelzI7rgQsWYrzw.otf",500:"http://fonts.gstatic.com/s/notosanskr/v25/Pby7FmXiEBPT4ITbgNA5CgmOIl3I7rgQsWYrzw.otf",700:"http://fonts.gstatic.com/s/notosanskr/v25/Pby7FmXiEBPT4ITbgNA5CgmOalvI7rgQsWYrzw.otf",900:"http://fonts.gstatic.com/s/notosanskr/v25/Pby7FmXiEBPT4ITbgNA5CgmOUlnI7rgQsWYrzw.otf",regular:"http://fonts.gstatic.com/s/notosanskr/v25/PbykFmXiEBPT4ITbgNA5Cgm20HTs4JMMuA.otf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Rubik",variants:["300","regular","500","600","700","800","900","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],version:"v18",lastModified:"2022-02-03",files:{300:"http://fonts.gstatic.com/s/rubik/v18/iJWZBXyIfDnIV5PNhY1KTN7Z-Yh-WYi1UE80V4bVkA.ttf",500:"http://fonts.gstatic.com/s/rubik/v18/iJWZBXyIfDnIV5PNhY1KTN7Z-Yh-NYi1UE80V4bVkA.ttf",600:"http://fonts.gstatic.com/s/rubik/v18/iJWZBXyIfDnIV5PNhY1KTN7Z-Yh-2Y-1UE80V4bVkA.ttf",700:"http://fonts.gstatic.com/s/rubik/v18/iJWZBXyIfDnIV5PNhY1KTN7Z-Yh-4I-1UE80V4bVkA.ttf",800:"http://fonts.gstatic.com/s/rubik/v18/iJWZBXyIfDnIV5PNhY1KTN7Z-Yh-h4-1UE80V4bVkA.ttf",900:"http://fonts.gstatic.com/s/rubik/v18/iJWZBXyIfDnIV5PNhY1KTN7Z-Yh-ro-1UE80V4bVkA.ttf",regular:"http://fonts.gstatic.com/s/rubik/v18/iJWZBXyIfDnIV5PNhY1KTN7Z-Yh-B4i1UE80V4bVkA.ttf","300italic":"http://fonts.gstatic.com/s/rubik/v18/iJWbBXyIfDnIV7nEt3KSJbVDV49rz8sDE0UwdYPFkJ1O.ttf",italic:"http://fonts.gstatic.com/s/rubik/v18/iJWbBXyIfDnIV7nEt3KSJbVDV49rz8tdE0UwdYPFkJ1O.ttf","500italic":"http://fonts.gstatic.com/s/rubik/v18/iJWbBXyIfDnIV7nEt3KSJbVDV49rz8tvE0UwdYPFkJ1O.ttf","600italic":"http://fonts.gstatic.com/s/rubik/v18/iJWbBXyIfDnIV7nEt3KSJbVDV49rz8uDFEUwdYPFkJ1O.ttf","700italic":"http://fonts.gstatic.com/s/rubik/v18/iJWbBXyIfDnIV7nEt3KSJbVDV49rz8u6FEUwdYPFkJ1O.ttf","800italic":"http://fonts.gstatic.com/s/rubik/v18/iJWbBXyIfDnIV7nEt3KSJbVDV49rz8vdFEUwdYPFkJ1O.ttf","900italic":"http://fonts.gstatic.com/s/rubik/v18/iJWbBXyIfDnIV7nEt3KSJbVDV49rz8v0FEUwdYPFkJ1O.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Lora",variants:["regular","500","600","700","italic","500italic","600italic","700italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v23",lastModified:"2022-02-03",files:{500:"http://fonts.gstatic.com/s/lora/v23/0QI6MX1D_JOuGQbT0gvTJPa787wsuyJGmKxemMeZ.ttf",600:"http://fonts.gstatic.com/s/lora/v23/0QI6MX1D_JOuGQbT0gvTJPa787zAvCJGmKxemMeZ.ttf",700:"http://fonts.gstatic.com/s/lora/v23/0QI6MX1D_JOuGQbT0gvTJPa787z5vCJGmKxemMeZ.ttf",regular:"http://fonts.gstatic.com/s/lora/v23/0QI6MX1D_JOuGQbT0gvTJPa787weuyJGmKxemMeZ.ttf",italic:"http://fonts.gstatic.com/s/lora/v23/0QI8MX1D_JOuMw_hLdO6T2wV9KnW-MoFkqh8ndeZzZ0.ttf","500italic":"http://fonts.gstatic.com/s/lora/v23/0QI8MX1D_JOuMw_hLdO6T2wV9KnW-PgFkqh8ndeZzZ0.ttf","600italic":"http://fonts.gstatic.com/s/lora/v23/0QI8MX1D_JOuMw_hLdO6T2wV9KnW-BQCkqh8ndeZzZ0.ttf","700italic":"http://fonts.gstatic.com/s/lora/v23/0QI8MX1D_JOuMw_hLdO6T2wV9KnW-C0Ckqh8ndeZzZ0.ttf"},category:"serif",kind:"webfonts#webfont"},{family:"Mukta",variants:["200","300","regular","500","600","700","800"],subsets:["devanagari","latin","latin-ext"],version:"v12",lastModified:"2022-01-27",files:{200:"http://fonts.gstatic.com/s/mukta/v12/iJWHBXyXfDDVXbEOjFma-2HW7ZB_.ttf",300:"http://fonts.gstatic.com/s/mukta/v12/iJWHBXyXfDDVXbFqj1ma-2HW7ZB_.ttf",500:"http://fonts.gstatic.com/s/mukta/v12/iJWHBXyXfDDVXbEyjlma-2HW7ZB_.ttf",600:"http://fonts.gstatic.com/s/mukta/v12/iJWHBXyXfDDVXbEeiVma-2HW7ZB_.ttf",700:"http://fonts.gstatic.com/s/mukta/v12/iJWHBXyXfDDVXbF6iFma-2HW7ZB_.ttf",800:"http://fonts.gstatic.com/s/mukta/v12/iJWHBXyXfDDVXbFmi1ma-2HW7ZB_.ttf",regular:"http://fonts.gstatic.com/s/mukta/v12/iJWKBXyXfDDVXYnGp32S0H3f.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Nunito Sans",variants:["200","200italic","300","300italic","regular","italic","600","600italic","700","700italic","800","800italic","900","900italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v11",lastModified:"2022-01-27",files:{200:"http://fonts.gstatic.com/s/nunitosans/v11/pe03MImSLYBIv1o4X1M8cc9yAv5qWVAgVol-.ttf",300:"http://fonts.gstatic.com/s/nunitosans/v11/pe03MImSLYBIv1o4X1M8cc8WAf5qWVAgVol-.ttf",600:"http://fonts.gstatic.com/s/nunitosans/v11/pe03MImSLYBIv1o4X1M8cc9iB_5qWVAgVol-.ttf",700:"http://fonts.gstatic.com/s/nunitosans/v11/pe03MImSLYBIv1o4X1M8cc8GBv5qWVAgVol-.ttf",800:"http://fonts.gstatic.com/s/nunitosans/v11/pe03MImSLYBIv1o4X1M8cc8aBf5qWVAgVol-.ttf",900:"http://fonts.gstatic.com/s/nunitosans/v11/pe03MImSLYBIv1o4X1M8cc8-BP5qWVAgVol-.ttf","200italic":"http://fonts.gstatic.com/s/nunitosans/v11/pe01MImSLYBIv1o4X1M8cce4GxZrU1QCU5l-06Y.ttf","300italic":"http://fonts.gstatic.com/s/nunitosans/v11/pe01MImSLYBIv1o4X1M8cce4G3JoU1QCU5l-06Y.ttf",regular:"http://fonts.gstatic.com/s/nunitosans/v11/pe0qMImSLYBIv1o4X1M8cfe6Kdpickwp.ttf",italic:"http://fonts.gstatic.com/s/nunitosans/v11/pe0oMImSLYBIv1o4X1M8cce4I95Ad1wpT5A.ttf","600italic":"http://fonts.gstatic.com/s/nunitosans/v11/pe01MImSLYBIv1o4X1M8cce4GwZuU1QCU5l-06Y.ttf","700italic":"http://fonts.gstatic.com/s/nunitosans/v11/pe01MImSLYBIv1o4X1M8cce4G2JvU1QCU5l-06Y.ttf","800italic":"http://fonts.gstatic.com/s/nunitosans/v11/pe01MImSLYBIv1o4X1M8cce4G35sU1QCU5l-06Y.ttf","900italic":"http://fonts.gstatic.com/s/nunitosans/v11/pe01MImSLYBIv1o4X1M8cce4G1ptU1QCU5l-06Y.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Work Sans",variants:["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["latin","latin-ext","vietnamese"],version:"v16",lastModified:"2022-02-03",files:{100:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K0nWNigDp6_cOyA.ttf",200:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K8nXNigDp6_cOyA.ttf",300:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32KxfXNigDp6_cOyA.ttf",500:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K3vXNigDp6_cOyA.ttf",600:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K5fQNigDp6_cOyA.ttf",700:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K67QNigDp6_cOyA.ttf",800:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K8nQNigDp6_cOyA.ttf",900:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K-DQNigDp6_cOyA.ttf",regular:"http://fonts.gstatic.com/s/worksans/v16/QGY_z_wNahGAdqQ43RhVcIgYT2Xz5u32K0nXNigDp6_cOyA.ttf","100italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGU3moJo43ZKyDSQQ.ttf","200italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGUXmsJo43ZKyDSQQ.ttf","300italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGUgGsJo43ZKyDSQQ.ttf",italic:"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGU3msJo43ZKyDSQQ.ttf","500italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGU7GsJo43ZKyDSQQ.ttf","600italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGUAGwJo43ZKyDSQQ.ttf","700italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGUOWwJo43ZKyDSQQ.ttf","800italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGUXmwJo43ZKyDSQQ.ttf","900italic":"http://fonts.gstatic.com/s/worksans/v16/QGY9z_wNahGAdqQ43Rh_ebrnlwyYfEPxPoGUd2wJo43ZKyDSQQ.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Nanum Gothic",variants:["regular","700","800"],subsets:["korean","latin"],version:"v17",lastModified:"2019-07-22",files:{700:"http://fonts.gstatic.com/s/nanumgothic/v17/PN_oRfi-oW3hYwmKDpxS7F_LQv37zlEn14YEUQ.ttf",800:"http://fonts.gstatic.com/s/nanumgothic/v17/PN_oRfi-oW3hYwmKDpxS7F_LXv77zlEn14YEUQ.ttf",regular:"http://fonts.gstatic.com/s/nanumgothic/v17/PN_3Rfi-oW3hYwmKDpxS7F_z_tLfxno73g.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Fira Sans",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v15",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/firasans/v15/va9C4kDNxMZdWfMOD5Vn9IjOazP3dUTP.ttf",200:"http://fonts.gstatic.com/s/firasans/v15/va9B4kDNxMZdWfMOD5VnWKnuQR37fF3Wlg.ttf",300:"http://fonts.gstatic.com/s/firasans/v15/va9B4kDNxMZdWfMOD5VnPKruQR37fF3Wlg.ttf",500:"http://fonts.gstatic.com/s/firasans/v15/va9B4kDNxMZdWfMOD5VnZKvuQR37fF3Wlg.ttf",600:"http://fonts.gstatic.com/s/firasans/v15/va9B4kDNxMZdWfMOD5VnSKzuQR37fF3Wlg.ttf",700:"http://fonts.gstatic.com/s/firasans/v15/va9B4kDNxMZdWfMOD5VnLK3uQR37fF3Wlg.ttf",800:"http://fonts.gstatic.com/s/firasans/v15/va9B4kDNxMZdWfMOD5VnMK7uQR37fF3Wlg.ttf",900:"http://fonts.gstatic.com/s/firasans/v15/va9B4kDNxMZdWfMOD5VnFK_uQR37fF3Wlg.ttf","100italic":"http://fonts.gstatic.com/s/firasans/v15/va9A4kDNxMZdWfMOD5VvkrCqYTfVcFTPj0s.ttf","200italic":"http://fonts.gstatic.com/s/firasans/v15/va9f4kDNxMZdWfMOD5VvkrAGQBf_XljGllLX.ttf","300italic":"http://fonts.gstatic.com/s/firasans/v15/va9f4kDNxMZdWfMOD5VvkrBiQxf_XljGllLX.ttf",regular:"http://fonts.gstatic.com/s/firasans/v15/va9E4kDNxMZdWfMOD5VfkILKSTbndQ.ttf",italic:"http://fonts.gstatic.com/s/firasans/v15/va9C4kDNxMZdWfMOD5VvkojOazP3dUTP.ttf","500italic":"http://fonts.gstatic.com/s/firasans/v15/va9f4kDNxMZdWfMOD5VvkrA6Qhf_XljGllLX.ttf","600italic":"http://fonts.gstatic.com/s/firasans/v15/va9f4kDNxMZdWfMOD5VvkrAWRRf_XljGllLX.ttf","700italic":"http://fonts.gstatic.com/s/firasans/v15/va9f4kDNxMZdWfMOD5VvkrByRBf_XljGllLX.ttf","800italic":"http://fonts.gstatic.com/s/firasans/v15/va9f4kDNxMZdWfMOD5VvkrBuRxf_XljGllLX.ttf","900italic":"http://fonts.gstatic.com/s/firasans/v15/va9f4kDNxMZdWfMOD5VvkrBKRhf_XljGllLX.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Quicksand",variants:["300","regular","500","600","700"],subsets:["latin","latin-ext","vietnamese"],version:"v28",lastModified:"2022-02-03",files:{300:"http://fonts.gstatic.com/s/quicksand/v28/6xK-dSZaM9iE8KbpRA_LJ3z8mH9BOJvgkKEo18G0wx40QDw.ttf",500:"http://fonts.gstatic.com/s/quicksand/v28/6xK-dSZaM9iE8KbpRA_LJ3z8mH9BOJvgkM0o18G0wx40QDw.ttf",600:"http://fonts.gstatic.com/s/quicksand/v28/6xK-dSZaM9iE8KbpRA_LJ3z8mH9BOJvgkCEv18G0wx40QDw.ttf",700:"http://fonts.gstatic.com/s/quicksand/v28/6xK-dSZaM9iE8KbpRA_LJ3z8mH9BOJvgkBgv18G0wx40QDw.ttf",regular:"http://fonts.gstatic.com/s/quicksand/v28/6xK-dSZaM9iE8KbpRA_LJ3z8mH9BOJvgkP8o18G0wx40QDw.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"PT Serif",variants:["regular","italic","700","700italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext"],version:"v16",lastModified:"2022-01-27",files:{700:"http://fonts.gstatic.com/s/ptserif/v16/EJRSQgYoZZY2vCFuvAnt65qVXSr3pNNB.ttf",regular:"http://fonts.gstatic.com/s/ptserif/v16/EJRVQgYoZZY2vCFuvDFRxL6ddjb-.ttf",italic:"http://fonts.gstatic.com/s/ptserif/v16/EJRTQgYoZZY2vCFuvAFTzrq_cyb-vco.ttf","700italic":"http://fonts.gstatic.com/s/ptserif/v16/EJRQQgYoZZY2vCFuvAFT9gaQVy7VocNB6Iw.ttf"},category:"serif",kind:"webfonts#webfont"},{family:"Hind Siliguri",variants:["300","regular","500","600","700"],subsets:["bengali","latin","latin-ext"],version:"v11",lastModified:"2022-01-27",files:{300:"http://fonts.gstatic.com/s/hindsiliguri/v11/ijwOs5juQtsyLLR5jN4cxBEoRDf44uEfKiGvxts.ttf",500:"http://fonts.gstatic.com/s/hindsiliguri/v11/ijwOs5juQtsyLLR5jN4cxBEoRG_54uEfKiGvxts.ttf",600:"http://fonts.gstatic.com/s/hindsiliguri/v11/ijwOs5juQtsyLLR5jN4cxBEoREP-4uEfKiGvxts.ttf",700:"http://fonts.gstatic.com/s/hindsiliguri/v11/ijwOs5juQtsyLLR5jN4cxBEoRCf_4uEfKiGvxts.ttf",regular:"http://fonts.gstatic.com/s/hindsiliguri/v11/ijwTs5juQtsyLLR5jN4cxBEofJvQxuk0Nig.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Titillium Web",variants:["200","200italic","300","300italic","regular","italic","600","600italic","700","700italic","900"],subsets:["latin","latin-ext"],version:"v14",lastModified:"2022-01-27",files:{200:"http://fonts.gstatic.com/s/titilliumweb/v14/NaPDcZTIAOhVxoMyOr9n_E7ffAzHKIx5YrSYqWM.ttf",300:"http://fonts.gstatic.com/s/titilliumweb/v14/NaPDcZTIAOhVxoMyOr9n_E7ffGjEKIx5YrSYqWM.ttf",600:"http://fonts.gstatic.com/s/titilliumweb/v14/NaPDcZTIAOhVxoMyOr9n_E7ffBzCKIx5YrSYqWM.ttf",700:"http://fonts.gstatic.com/s/titilliumweb/v14/NaPDcZTIAOhVxoMyOr9n_E7ffHjDKIx5YrSYqWM.ttf",900:"http://fonts.gstatic.com/s/titilliumweb/v14/NaPDcZTIAOhVxoMyOr9n_E7ffEDBKIx5YrSYqWM.ttf","200italic":"http://fonts.gstatic.com/s/titilliumweb/v14/NaPFcZTIAOhVxoMyOr9n_E7fdMbewI1zZpaduWMmxA.ttf","300italic":"http://fonts.gstatic.com/s/titilliumweb/v14/NaPFcZTIAOhVxoMyOr9n_E7fdMbepI5zZpaduWMmxA.ttf",regular:"http://fonts.gstatic.com/s/titilliumweb/v14/NaPecZTIAOhVxoMyOr9n_E7fRMTsDIRSfr0.ttf",italic:"http://fonts.gstatic.com/s/titilliumweb/v14/NaPAcZTIAOhVxoMyOr9n_E7fdMbmCKZXbr2BsA.ttf","600italic":"http://fonts.gstatic.com/s/titilliumweb/v14/NaPFcZTIAOhVxoMyOr9n_E7fdMbe0IhzZpaduWMmxA.ttf","700italic":"http://fonts.gstatic.com/s/titilliumweb/v14/NaPFcZTIAOhVxoMyOr9n_E7fdMbetIlzZpaduWMmxA.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Noto Sans TC",variants:["100","300","regular","500","700","900"],subsets:["chinese-traditional","latin"],version:"v24",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/notosanstc/v24/-nFlOG829Oofr2wohFbTp9i9WyEJIfNZ1sjy.otf",300:"http://fonts.gstatic.com/s/notosanstc/v24/-nFkOG829Oofr2wohFbTp9i9kwMvDd1V39Hr7g.otf",500:"http://fonts.gstatic.com/s/notosanstc/v24/-nFkOG829Oofr2wohFbTp9i9ywIvDd1V39Hr7g.otf",700:"http://fonts.gstatic.com/s/notosanstc/v24/-nFkOG829Oofr2wohFbTp9i9gwQvDd1V39Hr7g.otf",900:"http://fonts.gstatic.com/s/notosanstc/v24/-nFkOG829Oofr2wohFbTp9i9uwYvDd1V39Hr7g.otf",regular:"http://fonts.gstatic.com/s/notosanstc/v24/-nF7OG829Oofr2wohFbTp9iFOSsLA_ZJ1g.otf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Inconsolata",variants:["200","300","regular","500","600","700","800","900"],subsets:["latin","latin-ext","vietnamese"],version:"v21",lastModified:"2021-01-30",files:{200:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7LppwU8aRr8lleY2co.ttf",300:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7Lpp9s8aRr8lleY2co.ttf",500:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7Lpp7c8aRr8lleY2co.ttf",600:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7Lpp1s7aRr8lleY2co.ttf",700:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7Lpp2I7aRr8lleY2co.ttf",800:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7LppwU7aRr8lleY2co.ttf",900:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7Lppyw7aRr8lleY2co.ttf",regular:"http://fonts.gstatic.com/s/inconsolata/v21/QldgNThLqRwH-OJ1UHjlKENVzkWGVkL3GZQmAwLYxYWI2qfdm7Lpp4U8aRr8lleY2co.ttf"},category:"monospace",kind:"webfonts#webfont"},{family:"Noto Serif",variants:["regular","italic","700","700italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v20",lastModified:"2022-01-27",files:{700:"http://fonts.gstatic.com/s/notoserif/v20/ga6Law1J5X9T9RW6j9bNdOwzTRCUcM1IKoY.ttf",regular:"http://fonts.gstatic.com/s/notoserif/v20/ga6Iaw1J5X9T9RW6j9bNTFAcaRi_bMQ.ttf",italic:"http://fonts.gstatic.com/s/notoserif/v20/ga6Kaw1J5X9T9RW6j9bNfFIWbTq6fMRRMw.ttf","700italic":"http://fonts.gstatic.com/s/notoserif/v20/ga6Vaw1J5X9T9RW6j9bNfFIu0RWedO9NOoYIDg.ttf"},category:"serif",kind:"webfonts#webfont"},{family:"Barlow",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],subsets:["latin","latin-ext","vietnamese"],version:"v11",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/barlow/v11/7cHrv4kjgoGqM7E3b8s8yn4hnCci.ttf",200:"http://fonts.gstatic.com/s/barlow/v11/7cHqv4kjgoGqM7E3w-oc4FAtlT47dw.ttf",300:"http://fonts.gstatic.com/s/barlow/v11/7cHqv4kjgoGqM7E3p-kc4FAtlT47dw.ttf",500:"http://fonts.gstatic.com/s/barlow/v11/7cHqv4kjgoGqM7E3_-gc4FAtlT47dw.ttf",600:"http://fonts.gstatic.com/s/barlow/v11/7cHqv4kjgoGqM7E30-8c4FAtlT47dw.ttf",700:"http://fonts.gstatic.com/s/barlow/v11/7cHqv4kjgoGqM7E3t-4c4FAtlT47dw.ttf",800:"http://fonts.gstatic.com/s/barlow/v11/7cHqv4kjgoGqM7E3q-0c4FAtlT47dw.ttf",900:"http://fonts.gstatic.com/s/barlow/v11/7cHqv4kjgoGqM7E3j-wc4FAtlT47dw.ttf","100italic":"http://fonts.gstatic.com/s/barlow/v11/7cHtv4kjgoGqM7E_CfNYwHoDmTcibrA.ttf","200italic":"http://fonts.gstatic.com/s/barlow/v11/7cHsv4kjgoGqM7E_CfP04Voptzsrd6m9.ttf","300italic":"http://fonts.gstatic.com/s/barlow/v11/7cHsv4kjgoGqM7E_CfOQ4loptzsrd6m9.ttf",regular:"http://fonts.gstatic.com/s/barlow/v11/7cHpv4kjgoGqM7EPC8E46HsxnA.ttf",italic:"http://fonts.gstatic.com/s/barlow/v11/7cHrv4kjgoGqM7E_Ccs8yn4hnCci.ttf","500italic":"http://fonts.gstatic.com/s/barlow/v11/7cHsv4kjgoGqM7E_CfPI41optzsrd6m9.ttf","600italic":"http://fonts.gstatic.com/s/barlow/v11/7cHsv4kjgoGqM7E_CfPk5Foptzsrd6m9.ttf","700italic":"http://fonts.gstatic.com/s/barlow/v11/7cHsv4kjgoGqM7E_CfOA5Voptzsrd6m9.ttf","800italic":"http://fonts.gstatic.com/s/barlow/v11/7cHsv4kjgoGqM7E_CfOc5loptzsrd6m9.ttf","900italic":"http://fonts.gstatic.com/s/barlow/v11/7cHsv4kjgoGqM7E_CfO451optzsrd6m9.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Karla",variants:["200","300","regular","500","600","700","800","200italic","300italic","italic","500italic","600italic","700italic","800italic"],subsets:["latin","latin-ext"],version:"v21",lastModified:"2022-02-03",files:{200:"http://fonts.gstatic.com/s/karla/v21/qkBIXvYC6trAT55ZBi1ueQVIjQTDeJqqFENLR7fHGw.ttf",300:"http://fonts.gstatic.com/s/karla/v21/qkBIXvYC6trAT55ZBi1ueQVIjQTDppqqFENLR7fHGw.ttf",500:"http://fonts.gstatic.com/s/karla/v21/qkBIXvYC6trAT55ZBi1ueQVIjQTDypqqFENLR7fHGw.ttf",600:"http://fonts.gstatic.com/s/karla/v21/qkBIXvYC6trAT55ZBi1ueQVIjQTDJp2qFENLR7fHGw.ttf",700:"http://fonts.gstatic.com/s/karla/v21/qkBIXvYC6trAT55ZBi1ueQVIjQTDH52qFENLR7fHGw.ttf",800:"http://fonts.gstatic.com/s/karla/v21/qkBIXvYC6trAT55ZBi1ueQVIjQTDeJ2qFENLR7fHGw.ttf",regular:"http://fonts.gstatic.com/s/karla/v21/qkBIXvYC6trAT55ZBi1ueQVIjQTD-JqqFENLR7fHGw.ttf","200italic":"http://fonts.gstatic.com/s/karla/v21/qkBKXvYC6trAT7RQNNK2EG7SIwPWMNnCV0lPZbLXGxGR.ttf","300italic":"http://fonts.gstatic.com/s/karla/v21/qkBKXvYC6trAT7RQNNK2EG7SIwPWMNkcV0lPZbLXGxGR.ttf",italic:"http://fonts.gstatic.com/s/karla/v21/qkBKXvYC6trAT7RQNNK2EG7SIwPWMNlCV0lPZbLXGxGR.ttf","500italic":"http://fonts.gstatic.com/s/karla/v21/qkBKXvYC6trAT7RQNNK2EG7SIwPWMNlwV0lPZbLXGxGR.ttf","600italic":"http://fonts.gstatic.com/s/karla/v21/qkBKXvYC6trAT7RQNNK2EG7SIwPWMNmcUElPZbLXGxGR.ttf","700italic":"http://fonts.gstatic.com/s/karla/v21/qkBKXvYC6trAT7RQNNK2EG7SIwPWMNmlUElPZbLXGxGR.ttf","800italic":"http://fonts.gstatic.com/s/karla/v21/qkBKXvYC6trAT7RQNNK2EG7SIwPWMNnCUElPZbLXGxGR.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Heebo",variants:["100","200","300","regular","500","600","700","800","900"],subsets:["hebrew","latin"],version:"v17",lastModified:"2022-02-03",files:{100:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1EiS2cckOnz02SXQ.ttf",200:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1ECSycckOnz02SXQ.ttf",300:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1E1yycckOnz02SXQ.ttf",500:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1EuyycckOnz02SXQ.ttf",600:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1EVyucckOnz02SXQ.ttf",700:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1EbiucckOnz02SXQ.ttf",800:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1ECSucckOnz02SXQ.ttf",900:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1EICucckOnz02SXQ.ttf",regular:"http://fonts.gstatic.com/s/heebo/v17/NGSpv5_NC0k9P_v6ZUCbLRAHxK1EiSycckOnz02SXQ.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Libre Franklin",variants:["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["latin","latin-ext","vietnamese"],version:"v11",lastModified:"2022-02-03",files:{100:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhLsSUB9rIb-JH1g.ttf",200:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhrsWUB9rIb-JH1g.ttf",300:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhcMWUB9rIb-JH1g.ttf",500:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhHMWUB9rIb-JH1g.ttf",600:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduh8MKUB9rIb-JH1g.ttf",700:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhycKUB9rIb-JH1g.ttf",800:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhrsKUB9rIb-JH1g.ttf",900:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhh8KUB9rIb-JH1g.ttf",regular:"http://fonts.gstatic.com/s/librefranklin/v11/jizOREVItHgc8qDIbSTKq4XkRg8T88bjFuXOnduhLsWUB9rIb-JH1g.ttf","100italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05oZ8RdDMTedX1sGE.ttf","200italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05ob8RNDMTedX1sGE.ttf","300italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05oYiRNDMTedX1sGE.ttf",italic:"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05oZ8RNDMTedX1sGE.ttf","500italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05oZORNDMTedX1sGE.ttf","600italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05oaiQ9DMTedX1sGE.ttf","700italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05oabQ9DMTedX1sGE.ttf","800italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05ob8Q9DMTedX1sGE.ttf","900italic":"http://fonts.gstatic.com/s/librefranklin/v11/jizMREVItHgc8qDIbSTKq4XkRiUawTk7f45UM9y05obVQ9DMTedX1sGE.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Josefin Sans",variants:["100","200","300","regular","500","600","700","100italic","200italic","300italic","italic","500italic","600italic","700italic"],subsets:["latin","latin-ext","vietnamese"],version:"v23",lastModified:"2022-02-03",files:{100:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3PZQNVED7rKGKxtqIqX5E-AVSJrOCfjY46_DjRXMFrLgTsQV0.ttf",200:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3PZQNVED7rKGKxtqIqX5E-AVSJrOCfjY46_LjQXMFrLgTsQV0.ttf",300:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3PZQNVED7rKGKxtqIqX5E-AVSJrOCfjY46_GbQXMFrLgTsQV0.ttf",500:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3PZQNVED7rKGKxtqIqX5E-AVSJrOCfjY46_ArQXMFrLgTsQV0.ttf",600:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3PZQNVED7rKGKxtqIqX5E-AVSJrOCfjY46_ObXXMFrLgTsQV0.ttf",700:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3PZQNVED7rKGKxtqIqX5E-AVSJrOCfjY46_N_XXMFrLgTsQV0.ttf",regular:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3PZQNVED7rKGKxtqIqX5E-AVSJrOCfjY46_DjQXMFrLgTsQV0.ttf","100italic":"http://fonts.gstatic.com/s/josefinsans/v23/Qw3JZQNVED7rKGKxtqIqX5EUCGZ2dIn0FyA96fCTtINhKibpUV3MEQ.ttf","200italic":"http://fonts.gstatic.com/s/josefinsans/v23/Qw3JZQNVED7rKGKxtqIqX5EUCGZ2dIn0FyA96fCTNIJhKibpUV3MEQ.ttf","300italic":"http://fonts.gstatic.com/s/josefinsans/v23/Qw3JZQNVED7rKGKxtqIqX5EUCGZ2dIn0FyA96fCT6oJhKibpUV3MEQ.ttf",italic:"http://fonts.gstatic.com/s/josefinsans/v23/Qw3JZQNVED7rKGKxtqIqX5EUCGZ2dIn0FyA96fCTtIJhKibpUV3MEQ.ttf","500italic":"http://fonts.gstatic.com/s/josefinsans/v23/Qw3JZQNVED7rKGKxtqIqX5EUCGZ2dIn0FyA96fCThoJhKibpUV3MEQ.ttf","600italic":"http://fonts.gstatic.com/s/josefinsans/v23/Qw3JZQNVED7rKGKxtqIqX5EUCGZ2dIn0FyA96fCTaoVhKibpUV3MEQ.ttf","700italic":"http://fonts.gstatic.com/s/josefinsans/v23/Qw3JZQNVED7rKGKxtqIqX5EUCGZ2dIn0FyA96fCTU4VhKibpUV3MEQ.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Libre Baskerville",variants:["regular","italic","700"],subsets:["latin","latin-ext"],version:"v13",lastModified:"2022-01-27",files:{700:"http://fonts.gstatic.com/s/librebaskerville/v13/kmKiZrc3Hgbbcjq75U4uslyuy4kn0qviTjYwI8Gcw6Oi.ttf",regular:"http://fonts.gstatic.com/s/librebaskerville/v13/kmKnZrc3Hgbbcjq75U4uslyuy4kn0pNeYRI4CN2V.ttf",italic:"http://fonts.gstatic.com/s/librebaskerville/v13/kmKhZrc3Hgbbcjq75U4uslyuy4kn0qNcaxYaDc2V2ro.ttf"},category:"serif",kind:"webfonts#webfont"},{family:"Arimo",variants:["regular","500","600","700","italic","500italic","600italic","700italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","latin","latin-ext","vietnamese"],version:"v24",lastModified:"2022-02-03",files:{500:"http://fonts.gstatic.com/s/arimo/v24/P5sfzZCDf9_T_3cV7NCUECyoxNk338xsBxDAVQI4aA.ttf",600:"http://fonts.gstatic.com/s/arimo/v24/P5sfzZCDf9_T_3cV7NCUECyoxNk3M8tsBxDAVQI4aA.ttf",700:"http://fonts.gstatic.com/s/arimo/v24/P5sfzZCDf9_T_3cV7NCUECyoxNk3CstsBxDAVQI4aA.ttf",regular:"http://fonts.gstatic.com/s/arimo/v24/P5sfzZCDf9_T_3cV7NCUECyoxNk37cxsBxDAVQI4aA.ttf",italic:"http://fonts.gstatic.com/s/arimo/v24/P5sdzZCDf9_T_10c3i9MeUcyat4iJY-ERBrEdwcoaKww.ttf","500italic":"http://fonts.gstatic.com/s/arimo/v24/P5sdzZCDf9_T_10c3i9MeUcyat4iJY-2RBrEdwcoaKww.ttf","600italic":"http://fonts.gstatic.com/s/arimo/v24/P5sdzZCDf9_T_10c3i9MeUcyat4iJY9aQxrEdwcoaKww.ttf","700italic":"http://fonts.gstatic.com/s/arimo/v24/P5sdzZCDf9_T_10c3i9MeUcyat4iJY9jQxrEdwcoaKww.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Dosis",variants:["200","300","regular","500","600","700","800"],subsets:["latin","latin-ext","vietnamese"],version:"v25",lastModified:"2022-02-03",files:{200:"http://fonts.gstatic.com/s/dosis/v25/HhyJU5sn9vOmLxNkIwRSjTVNWLEJt7MV3BkFTq4EPw.ttf",300:"http://fonts.gstatic.com/s/dosis/v25/HhyJU5sn9vOmLxNkIwRSjTVNWLEJabMV3BkFTq4EPw.ttf",500:"http://fonts.gstatic.com/s/dosis/v25/HhyJU5sn9vOmLxNkIwRSjTVNWLEJBbMV3BkFTq4EPw.ttf",600:"http://fonts.gstatic.com/s/dosis/v25/HhyJU5sn9vOmLxNkIwRSjTVNWLEJ6bQV3BkFTq4EPw.ttf",700:"http://fonts.gstatic.com/s/dosis/v25/HhyJU5sn9vOmLxNkIwRSjTVNWLEJ0LQV3BkFTq4EPw.ttf",800:"http://fonts.gstatic.com/s/dosis/v25/HhyJU5sn9vOmLxNkIwRSjTVNWLEJt7QV3BkFTq4EPw.ttf",regular:"http://fonts.gstatic.com/s/dosis/v25/HhyJU5sn9vOmLxNkIwRSjTVNWLEJN7MV3BkFTq4EPw.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Oxygen",variants:["300","regular","700"],subsets:["latin","latin-ext"],version:"v14",lastModified:"2022-01-27",files:{300:"http://fonts.gstatic.com/s/oxygen/v14/2sDcZG1Wl4LcnbuCJW8Db2-4C7wFZQ.ttf",700:"http://fonts.gstatic.com/s/oxygen/v14/2sDcZG1Wl4LcnbuCNWgDb2-4C7wFZQ.ttf",regular:"http://fonts.gstatic.com/s/oxygen/v14/2sDfZG1Wl4Lcnbu6iUcnZ0SkAg.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"PT Sans Narrow",variants:["regular","700"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext"],version:"v16",lastModified:"2022-01-27",files:{700:"http://fonts.gstatic.com/s/ptsansnarrow/v16/BngSUXNadjH0qYEzV7ab-oWlsbg95DiCUfzgRd-3.ttf",regular:"http://fonts.gstatic.com/s/ptsansnarrow/v16/BngRUXNadjH0qYEzV7ab-oWlsYCByxyKeuDp.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Mulish",variants:["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v10",lastModified:"2022-02-03",files:{200:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexRNRwaClGrw-PTY.ttf",300:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexc1RwaClGrw-PTY.ttf",500:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexaFRwaClGrw-PTY.ttf",600:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexU1WwaClGrw-PTY.ttf",700:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexXRWwaClGrw-PTY.ttf",800:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexRNWwaClGrw-PTY.ttf",900:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexTpWwaClGrw-PTY.ttf",regular:"http://fonts.gstatic.com/s/mulish/v10/1Ptyg83HX_SGhgqO0yLcmjzUAuWexZNRwaClGrw-PTY.ttf","200italic":"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsSqeOvHp47LTZFwA.ttf","300italic":"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsSd-OvHp47LTZFwA.ttf",italic:"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsSKeOvHp47LTZFwA.ttf","500italic":"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsSG-OvHp47LTZFwA.ttf","600italic":"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsS9-SvHp47LTZFwA.ttf","700italic":"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsSzuSvHp47LTZFwA.ttf","800italic":"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsSqeSvHp47LTZFwA.ttf","900italic":"http://fonts.gstatic.com/s/mulish/v10/1Ptwg83HX_SGhgqk2hAjQlW_mEuZ0FsSgOSvHp47LTZFwA.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"IBM Plex Sans",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],subsets:["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],version:"v13",lastModified:"2022-01-27",files:{100:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX-KVElMYYaJe8bpLHnCwDKjbLeEKxIedbzDw.ttf",200:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX9KVElMYYaJe8bpLHnCwDKjR7_MIZmdd_qFmo.ttf",300:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX9KVElMYYaJe8bpLHnCwDKjXr8MIZmdd_qFmo.ttf",500:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX9KVElMYYaJe8bpLHnCwDKjSL9MIZmdd_qFmo.ttf",600:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX9KVElMYYaJe8bpLHnCwDKjQ76MIZmdd_qFmo.ttf",700:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX9KVElMYYaJe8bpLHnCwDKjWr7MIZmdd_qFmo.ttf","100italic":"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX8KVElMYYaJe8bpLHnCwDKhdTmdKZMW9PjD3N8.ttf","200italic":"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX7KVElMYYaJe8bpLHnCwDKhdTm2Idscf3vBmpl8A.ttf","300italic":"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX7KVElMYYaJe8bpLHnCwDKhdTmvIRscf3vBmpl8A.ttf",regular:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYXgKVElMYYaJe8bpLHnCwDKtdbUFI5NadY.ttf",italic:"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX-KVElMYYaJe8bpLHnCwDKhdTeEKxIedbzDw.ttf","500italic":"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX7KVElMYYaJe8bpLHnCwDKhdTm5IVscf3vBmpl8A.ttf","600italic":"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX7KVElMYYaJe8bpLHnCwDKhdTmyIJscf3vBmpl8A.ttf","700italic":"http://fonts.gstatic.com/s/ibmplexsans/v13/zYX7KVElMYYaJe8bpLHnCwDKhdTmrINscf3vBmpl8A.ttf"},category:"sans-serif",kind:"webfonts#webfont"},{family:"Source Code Pro",variants:["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],subsets:["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],version:"v20",lastModified:"2022-02-03",files:{200:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DEyQhM5hTXUcdJg.ttf",300:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DJKQhM5hTXUcdJg.ttf",500:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DP6QhM5hTXUcdJg.ttf",600:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DBKXhM5hTXUcdJg.ttf",700:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DCuXhM5hTXUcdJg.ttf",800:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DEyXhM5hTXUcdJg.ttf",900:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DGWXhM5hTXUcdJg.ttf",regular:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_diYsKILxRpg3hIP6sJ7fM7PqPMcMnZFqUwX28DMyQhM5hTXUcdJg.ttf","200italic":"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTT7I1rSVcZZJiGpw.ttf","300italic":"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTTMo1rSVcZZJiGpw.ttf",italic:"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTTbI1rSVcZZJiGpw.ttf","500italic":"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTTXo1rSVcZZJiGpw.ttf","600italic":"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTTsoprSVcZZJiGpw.ttf","700italic":"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTTi4prSVcZZJiGpw.ttf","800italic":"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTT7IprSVcZZJiGpw.ttf","900italic":"http://fonts.gstatic.com/s/sourcecodepro/v20/HI_jiYsKILxRpg3hIP6sJ7fM7PqlOPHYvDP_W9O7GQTTxYprSVcZZJiGpw.ttf"},category:"monospace",kind:"webfonts#webfont"},{family:"Bebas Neue",variants:["regular"],subsets:["latin","latin-ext"],version:"v8",lastModified:"2022-01-27",files:{regular:"http://fonts.gstatic.com/s/bebasneue/v8/JTUSjIg69CK48gW7PXooxW5rygbi49c.ttf"},category:"display",kind:"webfonts#webfont"},{family:"Lobster",variants:["regular"],subsets:["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],version:"v27",lastModified:"2022-01-27",files:{regular:"http://fonts.gstatic.com/s/lobster/v27/neILzCirqoswsqX9_oWsMqEzSJQ.ttf"},category:"display",kind:"webfonts#webfont"}],Qy={kind:wW,items:kW},IW={class:"font-select__item-text"},SW=["onClick"],EW={__name:"EditTextFontSelectItem",props:{fontFamily:{type:String,required:!0},fontWeights:{type:Array,required:!0},fileType:{type:String,default:null},validFontWeightsMap:{type:Object,default:()=>({300:{title:"Light",value:"300"},regular:{title:"Regular",value:"400"},400:{title:"Regular",value:"400"},500:{title:"Medium",value:"500"},700:{title:"Bold",value:"700"}})},isOpen:{type:Boolean,default:!1}},emits:["update-font","hovering-font-family"],setup(t,{emit:e}){const o=t,n=e,s=c(()=>o.fontWeights.flatMap(l=>o.validFontWeightsMap[l]||[])),a=c(()=>s.value.length>1);return(l,i)=>{const r=ct("qa");return d(),v("div",null,[O((d(),v("div",Fe({ref:"fontItemButton",class:["font-select__item text-body-2",{"font-select__item--active":t.isOpen}],style:{fontFamily:t.fontFamily},[f(ko)||""]:f(Wd),onMousemove:i[0]||(i[0]=u=>n("hovering-font-family",t.fontFamily)),onClick:i[1]||(i[1]=u=>n("update-font",{fontFamily:t.fontFamily,fontWeight:400,...t.fileType?{fileType:t.fileType}:{}}))}),[m("p",IW,w(t.fontFamily),1),h(qt,{name:"chevron-right-small",class:rt({hidden:!a.value})},null,8,["class"])],16)),[[r,`edittext-textfont-option-${t.fontFamily}-in-use`]]),a.value&&t.isOpen?(d(),S(ve,{key:0,"target-ref":l.$refs.fontItemButton,"auto-update":"",placement:"right-start",offset:-4,"portal-selector":f(So)},{default:_(()=>[m("div",Fe({[f(ko)||""]:f(Wd),class:"font-select__item-options"}),[(d(!0),v(dt,null,zt(s.value,({title:u,value:p})=>O((d(),v("div",{key:p,class:"font-select__item-option text-body-2",style:ne({fontFamily:t.fontFamily,fontWeight:p}),onClick:g=>n("update-font",{fontFamily:t.fontFamily,fontWeight:p})},[j(w(u),1)],12,SW)),[[r,`edittext-textfont-option-${t.fontFamily}`]])),128))],16)]),_:1},8,["target-ref","portal-selector"])):B("",!0)])}}},xW=H(EW,[["__scopeId","data-v-ec62858d"]]),W_="loading",q_="success",Y_="error",TW=q({components:{Popup:ve,ZyroSvgDeprecated:qt,ZyroLoader:Ue,EditTextFontSelectItem:xW},props:{isOpen:{type:Boolean,required:!0},targetRef:{type:HTMLElement,default:null},autoUpdate:{type:Boolean,default:!1},placement:{type:String,default:"bottom-start"},offset:{type:Number,default:4},isFontWeightSelectionEnabled:{type:Boolean,default:!0}},emits:["click-outside","update","close"],setup(){const t=Bt(),{editor:e}=wi(),{isAiBuilderMode:o}=vo(),{site:n}=ai(t),s=Qy.items;return{UPLOAD_STATE_LOADING:W_,UPLOAD_STATE_SUCCESS:q_,UPLOAD_STATE_ERROR:Y_,editor:e,mostPopularGoogleFontsArray:s,DATA_ATTRIBUTE_SELECTOR:ko,DATA_ATTRIBUTE_SELECTOR_FONT_SELECT:Wd,SELECTOR_DATA_PORTAL_BUILDER_PREVIEW:So,isAiBuilderMode:o,website:n}},data(){return{lastHoveredFont:null,uploadState:null}},computed:{...Ae(["websiteId","currentElementId"]),...Ae("fonts",["googleFonts"]),...le("assets",["customFonts"]),...le(["siteElements","headerBlock"]),fontsInUse(){var n;const t=(n=this.editor)==null?void 0:n.getHTML(),e=Object.keys(this.siteElements).filter(s=>s!==this.currentElementId).map(s=>this.siteElements[s].content).join(),o=[t,e].join();return s8({siteData:this.website,html:o,customFonts:this.customFonts,googleFonts:this.googleFonts})}},watch:{isOpen(t){t||(this.lastHoveredFont=null)}},methods:{...be("assets",["fetchAssets"]),getFontFamilyWeights(t){var e;return((e=this.mostPopularGoogleFontsArray.find(({family:o})=>o===t))==null?void 0:e.variants)??[400]},updateFont({fontFamily:t,fontWeight:e,fileType:o}){this.$emit("update",{fontFamily:t,fontWeight:e,fileType:o})},async uploadFiles(t){var o,n;const e=t.target.files[0];this.uploadState={type:W_,text:this.$t("builder.editText.uploadingFont",[e.name])};try{const{status:s,data:a}=await yR(e,this.websiteId);s===200&&(this.fetchAssets(),this.uploadState={type:q_,text:this.$t("builder.editText.fontUploadedSuccessfully",[a.name.split(".")[0]]),showClose:!0})}catch(s){this.uploadState={type:Y_,text:((n=(o=s==null?void 0:s.response)==null?void 0:o.data)==null?void 0:n.message)||"",showClose:!0}}}}}),CW={class:"font-select-container"},PW={class:"font-select__group"},BW={class:"font-select__title"},AW={class:"font-select__description"},DW={key:0,class:"font-select__group"},zW={class:"font-select__title"},$W={class:"font-select__upload-button-container"},LW={class:"font-select__group"},OW={class:"font-select__title"},RW={key:0,class:"upload-state__message"},MW={key:1,class:"upload-state__message"},HW={key:2,class:"upload-state__message"},NW={class:"error-color"};function GW(t,e,o,n,s,a){const l=G("EditTextFontSelectItem"),i=G("ZyroSvgDeprecated"),r=G("ZyroLoader"),u=G("Popup"),p=ct("qa");return t.isOpen?(d(),S(u,{key:0,"target-ref":t.targetRef,placement:t.placement,offset:t.offset,"auto-update":t.autoUpdate,"portal-selector":t.SELECTOR_DATA_PORTAL_BUILDER_PREVIEW,onClickOutside:e[6]||(e[6]=g=>t.$emit("click-outside"))},{default:_(()=>[m("div",CW,[m("div",Fe({class:"font-select",[t.DATA_ATTRIBUTE_SELECTOR||""]:t.DATA_ATTRIBUTE_SELECTOR_FONT_SELECT,onScroll:e[3]||(e[3]=g=>t.lastHoveredFont=null)}),[m("div",PW,[m("div",BW,w(t.$t("common.inUse"))+": ",1),(d(!0),v(dt,null,zt(t.fontsInUse,g=>(d(),S(l,{key:`${g.family}-in-use`,"font-family":g.family,"font-weights":t.isFontWeightSelectionEnabled?t.getFontFamilyWeights(g.family):[],"is-open":t.isOpen&&t.lastHoveredFont===`${g.family}-in-use`,onHoveringFontFamily:b=>t.lastHoveredFont=`${g.family}-in-use`,onUpdateFont:t.updateFont},null,8,["font-family","font-weights","is-open","onHoveringFontFamily","onUpdateFont"]))),128)),m("div",AW,w(t.$t("builder.usedFontsCountDisclaimer")),1)]),t.isAiBuilderMode?B("",!0):(d(),v("div",DW,[m("div",zW,w(t.$t("common.myFonts"))+": ",1),(d(!0),v(dt,null,zt(t.customFonts,g=>O((d(),S(l,{key:g.family,"font-family":g.family,"font-weights":[],"file-type":g.fileType,"is-open":t.isOpen&&t.lastHoveredFont===g.family,onHoveringFontFamily:b=>t.lastHoveredFont=g.family,onUpdateFont:t.updateFont},null,8,["font-family","file-type","is-open","onHoveringFontFamily","onUpdateFont"])),[[p,`uploaded-${g.family}-font`]])),128)),m("div",$W,[O((d(),v("button",{class:"font-select__upload-button text-body-2",onClick:e[0]||(e[0]=g=>t.$refs.fileInput.click()),onMouseenter:e[1]||(e[1]=g=>t.lastHoveredFont=null)},[h(i,{class:"font-select__upload-button-icon",name:"upload"}),j(" "+w(t.$t("common.upload")),1)],32)),[[p,"fontupload-button"]]),O(m("input",{ref:"fileInput",type:"file",accept:".woff, .woff2, .ttf, .otf",name:"images",multiple:"",onChange:e[2]||(e[2]=(...g)=>t.uploadFiles&&t.uploadFiles(...g))},null,544),[[Qe,!1],[p,"builder-input-image"]])])])),m("div",LW,[m("div",OW,w(t.$t("common.all"))+": ",1),(d(!0),v(dt,null,zt(t.mostPopularGoogleFontsArray,g=>(d(),S(l,{key:g.family,"font-family":g.family,"font-weights":t.isFontWeightSelectionEnabled?g.variants:[],"is-open":t.isOpen&&t.lastHoveredFont===g.family,onHoveringFontFamily:b=>t.lastHoveredFont=g.family,onUpdateFont:t.updateFont},null,8,["font-family","font-weights","is-open","onHoveringFontFamily","onUpdateFont"]))),128))])],16),t.uploadState?O((d(),v("div",{key:0,class:"upload-state",onMouseenter:e[5]||(e[5]=g=>t.lastHoveredFont=null)},[t.uploadState.type===t.UPLOAD_STATE_LOADING?(d(),v("div",RW,[h(r,{class:"upload-state__indication",size:"24px",weight:"3px",color:"var(--color-azure)"}),j(" "+w(t.uploadState.text),1)])):t.uploadState.type===t.UPLOAD_STATE_SUCCESS?(d(),v("div",MW,[h(i,{name:"check-round-green-light",class:"upload-state__indication success-color"}),j(" "+w(t.uploadState.text),1)])):t.uploadState.type===t.UPLOAD_STATE_ERROR?(d(),v("div",HW,[h(i,{name:"alert-round-red",class:"upload-state__indication error-color"}),m("p",NW,w(t.$t("common.uploadFailed")),1),j(" "+w(t.uploadState.text),1)])):B("",!0),t.uploadState.showClose?(d(),S(i,{key:3,class:"upload-state__close",name:"x",onClick:e[4]||(e[4]=g=>t.uploadState=null)})):B("",!0)],32)),[[p,"fontupload-progress-text"]]):B("",!0)])]),_:1},8,["target-ref","placement","offset","auto-update","portal-selector"])):B("",!0)}const um=H(TW,[["render",GW],["__scopeId","data-v-7ff09dcc"]]),FW=q({components:{ZyroLabel:Xt,FontSelect:um},props:{currentFontFamily:{type:String,required:!0},isFontWeightSelectionEnabled:{type:Boolean,default:!0},isOpen:{type:Boolean,required:!0}},emits:["set-font-family","toggle","close"]}),VW=t=>(ke("data-v-c954a9ba"),t=t(),Ie(),t),UW={class:"font-select"},jW={class:"font-select__current-font"},WW=VW(()=>m("div",{class:"font-select__separator"},null,-1)),qW={class:"font-select__text"};function YW(t,e,o,n,s,a){const l=G("ZyroLabel"),i=G("FontSelect"),r=ct("qa");return d(),v("div",UW,[h(l,{class:"font-select__label"},{default:_(()=>[j(w(t.$t("builder.editButton.customButtonStyles.text.font")),1)]),_:1}),O((d(),v("button",{ref:"fontSelectButton",type:"button",class:"font-select__text-font-button text-body-2",onClick:e[0]||(e[0]=u=>t.$emit("toggle"))},[m("span",jW,w(t.currentFontFamily),1),WW,m("span",qW,w(t.$t("common.change")),1)])),[[r,"buttonstylesettings-selectfont"]]),h(i,{"target-ref":t.$refs.fontSelectButton,"is-open":t.isOpen,placement:"right-start","is-font-weight-selection-enabled":t.isFontWeightSelectionEnabled,onUpdate:e[1]||(e[1]=u=>t.$emit("set-font-family",u)),onClickOutside:e[2]||(e[2]=u=>t.$emit("close"))},null,8,["target-ref","is-open","is-font-weight-selection-enabled"])])}const Xy=H(FW,[["render",YW],["__scopeId","data-v-c954a9ba"]]),EI=(t,e)=>(e?t.font.primary:t.font.secondary).split(",")[0].replace(/["']+/g,""),KW={class:"button-style-settings"},ZW={class:"button-style-settings__group"},QW={class:"button-style-settings__group"},XW={key:2},JW={key:3,class:"button-style-settings__group"},tq={class:"button-style-settings__group"},eq={key:2,class:"button-style-settings__group"},oq=10,nq=48,iq=0,sq=0,aq=10,K_=25,lq=q({__name:"ButtonStyleSettingsV2",props:{elementId:{}},emits:["set-button-style"],setup(t,{emit:e}){const o=t,n=e,{t:s}=_t(),{getters:a}=nt(),l=[{title:s("builder.editButton.customButtonStyles.normal")},{title:s("builder.editButton.customButtonStyles.hover")}],i=C(l[0]),r=C(!1),u=C(!1),p=C(!1),g=C(!1),b=c(()=>a["gui/isMobileMode"]),y=c(()=>a.currentBlock),k=c(()=>a.siteStyles),I=c(()=>o.elementId?a.siteElements[o.elementId]:null),E=c(()=>{var at;return(at=I.value)==null?void 0:at.settings}),T=c(()=>E.value.type),P=c(()=>k.value[`grid-button-${T.value}`]),z=c(()=>{var ft,tt;const at=(ft=I.value[b.value?"mobile":"desktop"])==null?void 0:ft.fontSize,ot=Number.parseInt((tt=k.value[`grid-button-${T.value}`])==null?void 0:tt["font-size"],10);return Number.parseInt(at||ot,10)}),L=c(()=>{var at;return E.value.styles.position?(at=X1(y.value,E.value.styles.position))==null?void 0:at.height:void 0}),D=c(()=>{var at;return E.value.styles.position?(at=X1(y.value,E.value.styles.position))==null?void 0:at.width:void 0}),$=c(()=>{var gt,Q;const at=((gt=I.value.desktop)==null?void 0:gt.height)||L.value,ot=((Q=I.value.desktop)==null?void 0:Q.width)||D.value,ft=typeof at=="number"?Math.ceil(at/2):K_,tt=typeof ot=="number"?Math.ceil(ot/2):K_;return Math.min(ft,tt)}),A=c(()=>{var ot;const at=Number.parseInt((ot=k.value[`grid-button-${T.value}`])==null?void 0:ot["border-radius"],10);return I.value.borderRadius??Math.min($.value,at)}),M=c(()=>{const at=I.value.fontFamily,ot=P.value["font-family"].includes("primary"),ft=EI(k.value,ot);return at||ft}),U=c(()=>i.value.title===l[1].title),Y=c(()=>I.value.backgroundColor||"rgb(0, 0, 0)"),F=c(()=>I.value.backgroundColorHover||"rgb(29, 30, 32)"),W=c(()=>I.value.fontColor||P.value.color),V=c(()=>I.value.fontColorHover||P.value["color-hover"]),K=c(()=>I.value.borderColor||P.value["border-color"]),Z=c(()=>I.value.borderColorHover||P.value["border-color-hover"]),N=c(()=>I.value.borderWidth||0),X=at=>{i.value=at},et=(at,{localStylesProperty:ot})=>{n("set-button-style",{[ot]:at})},pt=({fontFamily:at,fontWeight:ot,fileType:ft})=>{n("set-button-style",{fontFamily:at,fontWeight:Number.parseInt(ot,10),fileType:ft}),r.value=!1},st=at=>{n("set-button-style",{[b.value?se:ge]:{fontSize:at}})},J=at=>{n("set-button-style",{borderWidth:at,...I.value.borderColor?{}:{borderColor:"rgb(26, 26, 26)"}})},it=at=>{n("set-button-style",{borderRadius:at})};return(at,ot)=>{const ft=ct("qa");return d(),v("div",KW,[h(Fi,{class:"button-style-settings__button-state",controls:l,"active-control":i.value,"onUpdate:activeControl":X},null,8,["active-control"]),m("div",ZW,[U.value?O((d(),S(Fo,{key:0,"is-open":u.value,label:at.$t("builder.editButton.customButtonStyles.fillColor"),class:"button-style-settings__item",color:F.value,onClickOutside:ot[0]||(ot[0]=tt=>u.value=!1),onToggle:ot[1]||(ot[1]=tt=>u.value=!u.value),onUpdateColor:ot[2]||(ot[2]=tt=>et(tt,{localStylesProperty:"backgroundColorHover"}))},null,8,["is-open","label","color"])),[[ft,"button-style-settings-fill-color-picker-hover"]]):O((d(),S(Fo,{key:1,"is-open":u.value,label:at.$t("builder.editButton.customButtonStyles.fillColor"),class:"button-style-settings__item",color:Y.value,onClickOutside:ot[3]||(ot[3]=tt=>u.value=!1),onToggle:ot[4]||(ot[4]=tt=>u.value=!u.value),onUpdateColor:ot[5]||(ot[5]=tt=>et(tt,{localStylesProperty:"backgroundColor"}))},null,8,["is-open","label","color"])),[[ft,"button-style-settings-fill-color-picker-default"]])]),m("div",QW,[U.value?O((d(),S(Fo,{key:0,"is-open":p.value,label:at.$t("builder.editButton.customButtonStyles.textColor"),class:"button-style-settings__item",color:V.value,onClickOutside:ot[6]||(ot[6]=tt=>p.value=!1),onToggle:ot[7]||(ot[7]=tt=>p.value=!p.value),onUpdateColor:ot[8]||(ot[8]=tt=>et(tt,{localStylesProperty:"fontColorHover"}))},null,8,["is-open","label","color"])),[[ft,"button-style-settings-font-color-picker-hover"]]):O((d(),S(Fo,{key:1,"is-open":p.value,label:at.$t("builder.editButton.customButtonStyles.textColor"),class:"button-style-settings__item",color:W.value,onClickOutside:ot[9]||(ot[9]=tt=>p.value=!1),onToggle:ot[10]||(ot[10]=tt=>p.value=!p.value),onUpdateColor:ot[11]||(ot[11]=tt=>et(tt,{localStylesProperty:"fontColor"}))},null,8,["is-open","label","color"])),[[ft,"button-style-settings-font-color-picker-default"]]),U.value?B("",!0):(d(),v("div",XW,[h(Xy,{"current-font-family":M.value,"is-open":r.value,onSetFontFamily:pt,onToggle:ot[12]||(ot[12]=tt=>r.value=!r.value),onClose:ot[13]||(ot[13]=tt=>r.value=!1)},null,8,["current-font-family","is-open"])])),U.value?B("",!0):(d(),v("div",JW,[h(Xt,{class:"button-style-settings__label"},{default:_(()=>[j(w(at.$t("builder.editButton.customButtonStyles.text.size")),1)]),_:1}),O(h(Jo,{min:oq,max:nq,step:1,"has-number-input":"","model-value":z.value,"onUpdate:modelValue":st},null,8,["model-value"]),[[ft,"button-style-text-size-slider"]])]))]),m("div",tq,[U.value?O((d(),S(Fo,{key:0,"is-open":g.value,label:at.$t("builder.editButton.customButtonStyles.borderColor"),"portal-selector":f(So),class:"button-style-settings__item",color:Z.value,onClickOutside:ot[14]||(ot[14]=tt=>g.value=!1),onToggle:ot[15]||(ot[15]=tt=>g.value=!g.value),onUpdateColor:ot[16]||(ot[16]=tt=>et(tt,{localStylesProperty:"borderColorHover"}))},null,8,["is-open","label","portal-selector","color"])),[[ft,"button-style-settings-border-color-picker-default"]]):O((d(),S(Fo,{key:1,"is-open":g.value,label:at.$t("builder.editButton.customButtonStyles.borderColor"),"portal-selector":f(So),class:"button-style-settings__item",color:K.value,onClickOutside:ot[17]||(ot[17]=tt=>g.value=!1),onToggle:ot[18]||(ot[18]=tt=>g.value=!g.value),onUpdateColor:ot[19]||(ot[19]=tt=>et(tt,{localStylesProperty:"borderColor"}))},null,8,["is-open","label","portal-selector","color"])),[[ft,"button-style-settings-border-color-picker-default"]]),U.value?B("",!0):(d(),v("div",eq,[h(Xt,{class:"button-style-settings__label"},{default:_(()=>[j(w(at.$t("common.borderWidth")),1)]),_:1}),O(h(Jo,{min:sq,max:aq,step:1,"has-number-input":"","model-value":N.value,"onUpdate:modelValue":J},null,8,["model-value"]),[[ft,"button-style-border-width-slider"]]),h(Xt,{class:"button-style-settings__label"},{default:_(()=>[j(w(at.$t("common.cornerRadius")),1)]),_:1}),O(h(Jo,{min:iq,max:$.value,step:1,"has-number-input":"","model-value":A.value,"onUpdate:modelValue":it},null,8,["max","model-value"]),[[ft,"button-style-border-radius-slider"]])]))])])}}}),rq=H(lq,[["__scopeId","data-v-666c19c1"]]),xI=q({__name:"EditButtonTabStyle",props:{elementId:{}},setup(t){const e=t,{dispatch:o}=nt(),n=s=>{o("mergeElementData",{elementId:e.elementId,elementData:{...s}})};return(s,a)=>(d(),S(rq,{"element-id":s.elementId,onSetButtonStyle:n},null,8,["element-id"]))}}),Jy=q({components:{ZyroLabel:Xt,ZyroSvgDeprecated:qt},props:{modelValue:{type:String,default:null},options:{type:Object,validator:t=>Object.values(t).every(e=>e.icon),required:!0},optionsGridGap:{type:String,default:"16px"},label:{type:String,default:""},iconContainerPadding:{type:String,default:"18px 10px"},itemsPerRow:{type:Number,default:2},isTogglable:{type:Boolean,default:!1},groupName:{type:String,default:"group"},activeIconColor:{type:String,default:null},activeBackgroundColor:{type:String,default:null}},emits:["update:model-value","option-click"],computed:{computedStyles(){return{"--items-per-row":this.itemsPerRow,"--icon-container-padding":this.iconContainerPadding,"--icon-active-color":this.activeIconColor,"--background-active-color":this.activeBackgroundColor}}},methods:{updateCurrentSelection(t){const e=this.isTogglable&&t===this.modelValue;this.$emit("update:model-value",e?null:t)}}}),Z_=()=>{ue(t=>({"887ea1ca":t.optionsGridGap}))},Q_=Jy.setup;Jy.setup=Q_?(t,e)=>(Z_(),Q_(t,e)):Z_;const dq={class:"zyro-icon-select__options"},cq=["type","name","value","onChange","onClick"],uq={class:"zyro-icon-select__icon-container"},pq={class:"zyro-icon-select__name text-body-2"};function gq(t,e,o,n,s,a){const l=G("ZyroLabel"),i=G("ZyroSvgDeprecated"),r=ct("qa");return d(),v("div",{class:"zyro-icon-select",style:ne(t.computedStyles)},[t.label?(d(),S(l,{key:0},{default:_(()=>[j(w(t.label),1)]),_:1})):B("",!0),m("div",dq,[(d(!0),v(dt,null,zt(t.options,(u,p)=>O((d(),v("label",{key:`icon-${p}`,class:rt(["zyro-icon-select__label",{"zyro-icon-select__label--current":p===t.modelValue}])},[m("input",{class:"zyro-icon-select__input",type:t.isTogglable?"checkbox":"radio",name:t.isTogglable?u.name:t.groupName,value:p,onChange:g=>t.updateCurrentSelection(p),onClick:g=>t.$emit("option-click",p)},null,40,cq),m("div",uq,[h(i,{name:u.icon,class:"zyro-icon-select__icon",dimensions:u.iconDimensions||"42px"},null,8,["name","dimensions"])]),m("span",pq,w(u.name),1)],2)),[[r,`option-${p}`]])),128))])],4)}const Oi=H(Jy,[["render",gq],["__scopeId","data-v-575b3ec5"]]),rd=C(!1),dd=C(!1),Bh=C(""),Ah=C(""),Ml=C(null),Dh=C(!1),Hl=C(null),ts=({elementData:t,data:e,elementId:o,blockId:n}={})=>{const s=C(null),a=C(null),l=C(null),i=t||e||{},r=T=>`transition transition--${T}`,u=c(()=>{var L;const T=o&&vc.includes(i.type),P=!o&&!yc.includes(i.type);if(T||P)return"";const z=r((L=i==null?void 0:i.animation)==null?void 0:L.name);return n1.includes(i.type)?`${z} transition--root-hidden`:z}),p=c(()=>{const T=Ml.value&&o===Ml.value,P=Hl.value&&n===Hl.value;return!rd.value||Ml.value&&!T||Hl.value&&!P?"":Bh.value}),g=c(()=>dd.value?wa:null),b=async T=>{T.forEach(({target:P,isIntersecting:z})=>{var L;if(!z){P.removeAttribute(Qi);return}(L=l.value)==null||L.unobserve(P),P.setAttribute(Qi,wa)})},y=({root:T=null}={})=>{var P;(P=i.animation)!=null&&P.name&&(l.value=new IntersectionObserver(b,{threshold:0,root:T}))},k=async T=>{var P,z;if((P=i==null?void 0:i.animation)!=null&&P.name)if(await $e(),n1.includes(i.type)){const L=T==null?void 0:T.querySelectorAll(`[${qs}="${Qf}"]`),D=T==null?void 0:T.querySelectorAll(`[${qs}="${Or}"]`);[...L,...D].forEach(A=>{var M;return(M=l.value)==null?void 0:M.observe(A)})}else(z=l.value)==null||z.observe(T)},I=()=>{s.value&&a.value&&(window.clearTimeout(s.value),window.clearTimeout(a.value)),rd.value=!1,dd.value=!1},E=({animation:T,id:P=null,block:z=null})=>{I(),T!=="none"&&(Hl.value=z,Ml.value=P,Ah.value=T,rd.value=!0,Bh.value=r(Ah.value),s.value=setTimeout(()=>{dd.value=!0},500),a.value=setTimeout(()=>{rd.value=!1,dd.value=!1,Ml.value=null,Hl.value=null},2e3))};return Rt(Dh,async T=>{T&&(await $e(),Dh.value=!1)}),{intersectionObserver:l,animationClass:u,animationInEditorClass:Bh,animationInEditorComponentId:Ml,animationInEditorBlockId:Hl,isAnimationDisplayedInEditor:rd,isAnimationDisplayedInEditorActive:dd,animationInEditorName:Ah,addIntersectionObserver:y,observe:k,displayAnimationInEditor:E,shouldMountAnimationsInPreview:Dh,customAnimationClass:p,animationAttributeStateValue:g,addTransition:b}},mq=q({components:{NpsRateFeature:_o,ZyroIconSelect:Oi},props:{elementId:{type:String,default:""}},setup(t){const{state:e,getters:o,dispatch:n}=nt(),s=ii(),{t:a}=_t(),{displayAnimationInEditor:l}=ts(),{siteLanguages:i}=o,r={none:{name:a("builder.animationsSettingsNoAnimation"),icon:"crossed-circle",iconDimensions:"48px"},fade:{name:a("builder.animationsSettingsFade"),icon:"rectangle-grey",iconDimensions:"84px"},slide:{name:a("builder.animationsSettingsSlide"),icon:"slide-animation",iconDimensions:"84px"},scale:{name:a("builder.animationsSettingsScale"),icon:"scale-animation",iconDimensions:"84px"}},u=c(()=>e.currentLocale),p=c(()=>{const $=Object.keys(i).map(A=>i[A].blocks);return Object.fromEntries($.flatMap(A=>Object.entries(A)))}),g=c(()=>{const $=Object.keys(i).map(A=>i[A].elements);return Object.fromEntries($.flatMap(A=>Object.entries(A)))}),b=c(()=>sf({blocks:p.value})),y=c(()=>Object.fromEntries(Object.entries(i).map(([$,A])=>[$,sf({blocks:A.blocks})]))),k=c(()=>af({elements:g.value})),I=c(()=>Object.fromEntries(Object.entries(i).map(([$,A])=>[$,af({elements:A.elements})]))),E=c(()=>{var M;const $=[...Object.values(b.value),...Object.values(k.value)].find(U=>{var Y;return((Y=U.animation)==null?void 0:Y.type)===Ls}),A=(M=i[u.value].elements[t.elementId])==null?void 0:M.animation;return A?A.name:t.elementId&&!A||!$?"none":$.animation.name}),T=()=>{s.push({name:Js}),Et.logEvent({eventName:"website_builder.builder.previewed"})},P=$=>$==="none"?null:$,z=({animationName:$,elementId:A,type:M,locale:U})=>{n("mergeElementData",{elementId:A,elementData:{animation:$?{name:$,type:M}:null},locale:U})},L=({animationName:$,block:A,blockId:M,type:U,locale:Y})=>{const F={...A,animation:$?{name:$,type:U}:null},W=Qa(F);n("updateBlockData",{blockId:M,blockData:W,locale:Y})},D=$=>{if(E.value===$)return;const A=P($);t.elementId?z({animationName:A,elementId:t.elementId,type:rr,locale:u.value}):(Object.entries(y.value).forEach(([M,U])=>{Object.keys(U).forEach(Y=>{L({animationName:A,blockId:Y,type:Ls,locale:M,block:U[Y]})})}),Object.entries(I.value).forEach(([M,U])=>{Object.keys(U).forEach(Y=>{z({animationName:A,elementId:Y,type:Ls,locale:M})})})),n("undoRedo/createSnapshot"),Et.logEvent({eventName:"website_builder.styles_animation_style.selected",eventProperties:{animation:$,type:t.elementId?rr:Ls,location:t.elementId||"drawer"}})};return Et.logEvent({eventName:"website_builder.global_styles_animations.enter"}),{ANIMATION_TYPES:r,NPS_TYPE_FEATURE_GLOBAL_STYLES_ANIMATION:$0,displayAnimationInEditor:l,animationType:E,openPreview:T,setAnimation:D}}}),hq={class:"animations-library"},bq={key:0,class:"animations-library__text text-body-2"};function fq(t,e,o,n,s,a){const l=G("ZyroIconSelect"),i=G("i18n-t"),r=G("NpsRateFeature");return d(),v("div",null,[m("div",hq,[t.elementId?B("",!0):(d(),v("p",bq,w(t.$t("builder.animationsSettingsExplanation")),1)),h(l,{"model-value":t.animationType,options:t.ANIMATION_TYPES,"items-per-row":2,"icon-container-padding":"0","group-name":"animations","active-background-color":"var(--color-azure-lighter)",class:"animations-library__select text-body-2","onUpdate:modelValue":t.setAnimation,onOptionClick:e[0]||(e[0]=u=>t.displayAnimationInEditor({animation:u,id:t.elementId}))},null,8,["model-value","options","onUpdate:modelValue"]),t.elementId?B("",!0):(d(),S(i,{key:1,tag:"p",keypath:"builder.animationsSettingsText",class:"animations-library__text text-body-2"},{default:_(()=>[m("a",{class:"animations-library__link",onClick:e[1]||(e[1]=(...u)=>t.openPreview&&t.openPreview(...u))},w(t.$t("builder.animationsPreviewMode")),1)]),_:1}))]),t.elementId?B("",!0):(d(),S(r,{key:0,"feature-name":t.$t("builder.npsRateGlobalStyles"),type:t.NPS_TYPE_FEATURE_GLOBAL_STYLES_ANIMATION},null,8,["feature-name","type"]))])}const TI=H(mq,[["render",fq],["__scopeId","data-v-1a82c710"]]),yq=q({components:{AnimationsLibrary:TI},setup(){const{getters:t}=nt();return{currentElementId:c(()=>t.currentElementId)}}});function vq(t,e,o,n,s,a){const l=G("AnimationsLibrary");return d(),S(l,{"element-id":t.currentElementId},null,8,["element-id"])}const Es=H(yq,[["render",vq]]),_q={__name:"EditButton",emits:["close"],setup(t,{emit:e}){const{getters:o}=nt(),{t:n}=_t(),s=c(()=>o.currentElementId),a=c(()=>o.currentElementType),l=c(()=>o.currentElementBlockType),i=e,r=[{title:"Stripe",id:"stripe"},{title:n("common.product"),id:"ecommerce"},{title:n("common.general"),id:"general"},{title:n("common.style"),id:"style"},{title:n("common.layout"),id:"layout"},{title:n("common.animation"),id:"animation"}],u=c(()=>a.value===_g),p=c(()=>a.value===es),g=c(()=>l.value===Us),b=c(()=>{const E=g.value?["general","style","animation"]:["general","style","layout"];return u.value?[...E,"stripe"]:p.value?[...E,"ecommerce"]:E}),y=c(()=>r.filter(E=>b.value.includes(E.id))),k=C(y.value[0]),I=c(()=>u.value?n("common.stripeCheckout"):p.value?n("builder.ecommerceAddToBagButton"):n("builder.editButton.popupTitle"));return(E,T)=>(d(),S(zo,{type:"editor",title:I.value,tabs:y.value,"current-tab":k.value,"onUpdate:currentTab":T[6]||(T[6]=P=>k.value=P),onClose:T[7]||(T[7]=P=>i("close"))},{default:_(()=>[k.value.id==="general"?(d(),S(wI,{key:0,"element-id":s.value,onClose:T[0]||(T[0]=P=>i("close"))},null,8,["element-id"])):k.value.id==="ecommerce"?(d(),S(yj,{key:1,onClose:T[1]||(T[1]=P=>i("close"))})):k.value.id==="layout"?(d(),S(Pj,{key:2,onClose:T[2]||(T[2]=P=>i("close"))})):k.value.id==="stripe"?(d(),S(nW,{key:3,onClose:T[3]||(T[3]=P=>i("close"))})):k.value.id==="style"?(d(),S(xI,{key:4,"element-id":s.value,onClose:T[4]||(T[4]=P=>i("close"))},null,8,["element-id"])):k.value.id==="animation"?(d(),S(Es,{key:5,onClose:T[5]||(T[5]=P=>i("close"))})):B("",!0),p.value?B("",!0):(d(),S(_o,{key:6,class:"edit-button__nps","feature-name":E.$t("builder.npsRateButton"),type:f(k0)},null,8,["feature-name","type"]))]),_:1},8,["title","tabs","current-tab"]))}},CI=H(_q,[["__scopeId","data-v-99215c33"]]),pm=(t,{href:e}={})=>({href:e,type:c(()=>{var o;return(o=t.data.settings)==null?void 0:o.type}),fontSizeMobile:c(()=>{var o;return(o=t.data.mobile)==null?void 0:o.fontSize}),fontSizeDesktop:c(()=>{var o;return(o=t.data.desktop)==null?void 0:o.fontSize}),fontFamily:c(()=>t.data.fontFamily),fontWeight:c(()=>t.data.fontWeight),borderWidth:c(()=>t.data.borderWidth),borderRadius:c(()=>t.data.borderRadius),backgroundColor:c(()=>t.data.backgroundColor),fontColor:c(()=>t.data.fontColor),borderColor:c(()=>t.data.borderColor),backgroundColorHover:c(()=>t.data.backgroundColorHover),fontColorHover:c(()=>t.data.fontColorHover),borderColorHover:c(()=>t.data.borderColorHover),buttonType:c(()=>t.data.settings.isFormButton?"submit":null),tagName:c(()=>t.data.settings.isFormButton?"button":"a"),target:c(()=>t.data.target),rel:c(()=>t.data.rel),content:c(()=>t.data.content),mobileElementWidth:c(()=>t.data.mobile.width),mobileElementHeight:c(()=>t.data.mobile.height)}),wq=q({__name:"GridButtonProviderBuilder",props:{data:{},elementId:{},isActive:{type:Boolean},isPreviewMode:{type:Boolean}},setup(t){const e=t,{dispatch:o}=nt(),n=Bt(),{siteBlocks:s,sitePages:a,defaultLocale:l,site:i}=ai(n),r=async Z=>{var pt,st,J;if(Z.preventDefault(),e.data.settings.isFormButton)return;const[N,X]=(e.data.href||"").split("#"),et=N.split("/").pop();if(e.data.linkType===oe.PAGE&&e.data.linkedPageId){const it=Bc({defaultLocalePages:(pt=i.value.languages[l.value])==null?void 0:pt.pages}),at=Object.entries(a.value).some(([ot,{type:ft}])=>ft===Uo&&ot===e.data.linkedPageId);it&&at&&o("updateCurrentLocale",l.value),o("updateCurrentPageSlug",et),o("updateCurrentPageId",e.data.linkedPageId);return}if(e.data.linkType===oe.ANCHORED_SECTION&&e.data.linkedPageId){const it=(st=Object.entries(a.value).find(([,ft])=>ft.slug===et))==null?void 0:st[0],at=(J=Object.entries(s.value).find(([,ft])=>ft.htmlId===X))==null?void 0:J[0];if(await o("updateCurrentPageId",it),!at)return;const ot=document.querySelector(`[data-block-id="${at}"]`);if(!ot)return;window.requestAnimationFrame(()=>{var ft,tt;(tt=document.querySelector(`.${fc}`))==null||tt.scrollTo({top:document.querySelector(`.${sr}`)?ot.offsetTop-(((ft=document.querySelector(`.${sr}`))==null?void 0:ft.offsetHeight)||0):ot.offsetTop,behavior:"smooth"})});return}window.open(e.data.href,"_blank")},{tagName:u,href:p,target:g,rel:b,type:y,content:k,fontSizeMobile:I,fontSizeDesktop:E,fontFamily:T,fontWeight:P,borderWidth:z,borderRadius:L,backgroundColor:D,fontColor:$,borderColor:A,backgroundColorHover:M,fontColorHover:U,borderColorHover:Y,mobileElementWidth:F,mobileElementHeight:W}=pm(e,{href:c(()=>e.data.href)}),V=C(null),{closeElementEditPopupHandler:K}=li({elementId:e.elementId});return(Z,N)=>{var et;const X=ct("qa");return d(),v(dt,null,[O(h(sa,{ref_key:"buttonRef",ref:V,"data-element-ref":e.elementId,"tag-name":f(u),class:"layout-element__component layout-element__component--GridButton",href:f(p),target:f(g),rel:f(b),type:f(y),content:f(k),"font-size-mobile":f(I),"font-size-desktop":f(E),"font-family":f(T),"font-weight":f(P),"border-width":f(z),"border-radius":f(L),"background-color":f(D),"font-color":f($),"border-color":f(A),"background-color-hover":f(M),"font-color-hover":f(U),"border-color-hover":f(Y),"mobile-element-width":f(F),"mobile-element-height":f(W),"is-in-builder":"",onClick:N[0]||(N[0]=pt=>Z.isPreviewMode?r(pt):pt.preventDefault()),onDrag:N[1]||(N[1]=Yt(()=>{},["prevent"])),onDragstart:N[2]||(N[2]=Yt(()=>{},["prevent"]))},null,8,["data-element-ref","tag-name","href","target","rel","type","content","font-size-mobile","font-size-desktop","font-family","font-weight","border-width","border-radius","background-color","font-color","border-color","background-color-hover","font-color-hover","border-color-hover","mobile-element-width","mobile-element-height"]),[[X,"builder-gridelement-gridbutton"]]),Z.isPreviewMode?B("",!0):(d(),S(ri,{key:0,"target-ref":(et=V.value)==null?void 0:et.$el,"element-id":e.elementId,"is-element-active":e.isActive,"enter-edit-mode-button-title":Z.$t("builder.editButton.title")},{"edit-mode-popup":_(()=>[h(CI,{onClose:f(K)},null,8,["onClose"])]),_:1},8,["target-ref","element-id","is-element-active","enter-edit-mode-button-title"]))],64)}}}),kq=t=>{const e=c(()=>{var n;return(n=t.data.settings)==null?void 0:n.productId}),o=c(()=>{var n;return(n=t.data.settings)==null?void 0:n.productVariantId});return{productId:e,productVariantId:o}},Iq=["data-element-ref"],X_=32,Sq=q({__name:"GridEcommerceButtonProviderBuilder",props:{data:{},elementId:{},isActive:{type:Boolean},isPreviewMode:{type:Boolean}},setup(t){const e=t,{notify:o}=Le(),{dispatch:n}=nt(),s=me(),a=C(null),{content:l,type:i,fontSizeMobile:r,fontSizeDesktop:u,fontFamily:p,fontWeight:g,borderRadius:b,backgroundColor:y,fontColor:k,borderColor:I,backgroundColorHover:E,borderWidth:T,fontColorHover:P,borderColorHover:z}=pm(e,{href:c(()=>e.data.href)}),{productVariantId:L}=kq(e),{closeElementEditPopupHandler:D}=li({elementId:e.elementId}),$=c(()=>a.value?{top:`-${X_/2}px`,right:`-${X_/2}px`,position:"absolute",zIndex:1}:null),A=()=>{o({messageI18nKeyPath:"onlineStore.checkoutModalDisabledPreview",theme:"info"})},M=c(()=>{var V;return L.value&&((V=s.products)==null?void 0:V.some(K=>K.variants.some(Z=>Z.id===L.value)))?L.value:-1}),U=c(()=>/^(?!(\s*|-1)$)/.test(M.value)),Y=async()=>{var W;s.count>((W=s.products)==null?void 0:W.length)&&await s.fetchProducts({limit:s.count})},F=()=>{M.value!==L.value&&n("mergeElementData",{elementId:e.elementId,elementData:{settings:{productVariantId:M.value}}})};return Nt(async()=>{await Y(),F()}),(W,V)=>{var Z;const K=ct("qa");return d(),v(dt,null,[m("div",{"data-element-ref":W.elementId,class:"ecommerce-button layout-element__component layout-element__component--GridEcommerceButton"},[O(h(sa,{ref_key:"ecommerceRef",ref:a,"tag-name":"button",content:f(l),type:f(i),"font-size-mobile":f(r),"font-size-desktop":f(u),"font-family":f(p),"font-weight":f(g),"border-radius":f(b),"background-color":f(y),"font-color":f(k),"border-color":f(I),"background-color-hover":f(E),"font-color-hover":f(P),"border-color-hover":f(z),"border-width":f(T),"is-in-builder":"",onClick:V[0]||(V[0]=N=>W.isPreviewMode?A():N.preventDefault()),onDrag:V[1]||(V[1]=Yt(()=>{},["prevent"])),onDragstart:V[2]||(V[2]=Yt(()=>{},["prevent"]))},null,8,["content","type","font-size-mobile","font-size-desktop","font-family","font-weight","border-radius","background-color","font-color","border-color","background-color-hover","font-color-hover","border-color-hover","border-width"]),[[K,"builder-gridelement-gridecommercebutton"]]),!U.value&&!W.isPreviewMode?(d(),v("div",{key:0,style:ne($.value)},[h(Mo,{"toggle-event":"hover",mode:"dark",position:"right"},{trigger:_(()=>[h(qt,{name:"warning",dimensions:"32px"})]),default:_(()=>[j(" "+w(W.$t("builder.zyroEcommerceNoProducts")),1)]),_:1})],4)):B("",!0)],8,Iq),W.isPreviewMode?B("",!0):(d(),S(ri,{key:0,"target-ref":(Z=a.value)==null?void 0:Z.$el,"element-id":W.elementId,"is-element-active":W.isActive,"enter-edit-mode-button-title":W.$t("builder.editButton.title")},{"edit-mode-popup":_(()=>[h(CI,{onClose:f(D)},null,8,["onClose"])]),_:1},8,["target-ref","element-id","is-element-active","enter-edit-mode-button-title"]))],64)}}}),Eq=H(Sq,[["__scopeId","data-v-d9d7f841"]]),xq=["id"],Tq=["srcdoc"],Cq=q({__name:"GridEmbed",props:{srcdoc:{default:""},shouldRender:{type:Boolean,default:!1},isSandBoxed:{type:Boolean},id:{}},emits:["iframe-height-updated"],setup(t,{emit:e}){ue(r=>({"235e916e":l.value}));const o=t,n=e,s=C(),a=C(0),l=c(()=>a.value?`${a.value}px`:"auto"),i=r=>{r.data.action==="iframeHeightUpdated"&&o.id===r.data.id&&a.value!==r.data.height&&(a.value=r.data.height,n("iframe-height-updated",a.value))};return Nt(()=>{window.addEventListener("message",i)}),bl(()=>{window.removeEventListener("message",i)}),(r,u)=>{const p=ct("qa");return O((d(),v("div",{id:r.id,class:"grid-embed"},[r.shouldRender?O((d(),v("iframe",gn({key:0,ref_key:"gridEmbedIframeRef",ref:s,class:"grid-embed__iframe",srcdoc:r.srcdoc,title:"custom code element"},{...r.isSandBoxed&&{sandbox:"allow-scripts"}}),null,16,Tq)),[[p,"builder-gridelement-gridembed-iframe"]]):B("",!0)],8,xq)),[[p,"builder-gridelement-gridembed"]])}}}),Pq=H(Cq,[["__scopeId","data-v-0b938be5"]]),Bq="info",Aq="success",Dq="warning",zq="error",J_={[Bq]:{iconName:"info"},[Aq]:{iconName:"check_circle"},[Dq]:{iconName:"warning"},[zq]:{iconName:"error"}},$q=q({components:{Icon:lt},props:{title:{type:String,default:""},subtitle:{type:String,default:""},isWithIcon:{type:Boolean,default:!0},theme:{type:String,default:"info",validator:t=>t in J_}},setup(){return{BANNER_THEMES:J_,hasSlotContent:Hi}}}),Lq={class:"banner__content-wrapper"},Oq={class:"banner__content"},Rq={key:0,class:"banner__title text-bold-2"},Mq={key:0,class:"banner__subtitle text-body-2"},Hq={key:0,class:"banner__button-wrapper"};function Nq(t,e,o,n,s,a){const l=G("Icon");return d(),v("div",{class:rt(`banner banner--${t.theme}`)},[t.isWithIcon?(d(),S(l,{key:0,name:t.BANNER_THEMES[t.theme].iconName,class:"banner__icon"},null,8,["name"])):B("",!0),m("div",Lq,[m("div",Oq,[vt(t.$slots,"title",{},()=>[t.title?(d(),v("h3",Rq,w(t.title),1)):B("",!0)],!0),vt(t.$slots,"subtitle",{},()=>[t.subtitle?(d(),v("p",Mq,w(t.subtitle),1)):B("",!0)],!0)]),t.hasSlotContent(t.$slots.button)?(d(),v("div",Hq,[vt(t.$slots,"button",{},void 0,!0)])):B("",!0)])],2)}const Yc=H($q,[["render",Nq],["__scopeId","data-v-63160a98"]]),Gq=q({props:{id:{type:String},modelValue:{type:String,required:!0},placeholder:{type:String,default:""},color:{type:String,default:"",validator(t){return["","light"].includes(t)}},error:{type:String,default:""},theme:{type:String,default:"primary",validator:t=>["primary","secondary","hostinger"].includes(t)},isResizable:{type:Boolean,default:!1},maxlength:{type:[Number,String],default:""},autofocus:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},minHeight:{type:Number,default:130},isActive:{type:Boolean,default:!1}},emits:["update:model-value","text-area-blur","text-area-focus"]}),Fq=["id","autofocus","placeholder","disabled","maxlength","value"];function Vq(t,e,o,n,s,a){return d(),v("textarea",{id:t.id||void 0,ref:"textareaRef",class:rt(["zyro-textarea",[{[`zyro-textarea--${t.theme}`]:t.theme},{"text-body-2":t.theme==="primary"},{"text-body-1":t.theme==="secondary"},{"zyro-textarea--light":t.color},{"zyro-textarea--error":t.error},{"zyro-textarea--resizable":t.isResizable},{"zyro-textarea--min-height":t.minHeight},{"zyro-textarea--active":t.isActive}]]),style:ne({"--zyro-textarea-min-height":t.minHeight?`${t.minHeight}px`:"auto"}),autofocus:t.autofocus,placeholder:t.placeholder,disabled:t.disabled,maxlength:t.maxlength,value:t.modelValue,autocomplete:"off",onBlur:e[0]||(e[0]=l=>t.$emit("text-area-blur",l)),onFocus:e[1]||(e[1]=l=>t.$emit("text-area-focus",l)),onInput:e[2]||(e[2]=l=>t.$emit("update:model-value",l.target.value))},null,46,Fq)}const Kc=H(Gq,[["render",Vq],["__scopeId","data-v-e7f0f4aa"]]),Uq={class:"code-editor"},jq={__name:"ZyroCodeEditor",props:{modelValue:{type:String,default:""}},emits:["update:model-value"],setup(t,{emit:e}){const o=t,n=e,s=C(null);return Nt(()=>{const a=s.value.$el;a.focus({preventScroll:!0}),a.setSelectionRange&&a.setSelectionRange(a.value.length,a.value.length)}),(a,l)=>(d(),v("div",Uq,[h(Kc,{ref_key:"codeEditorInput",ref:s,autofocus:"",class:"code-editor__text-area","min-height":262,"model-value":o.modelValue,"onUpdate:modelValue":l[0]||(l[0]=i=>n("update:model-value",i))},null,8,["model-value"])]))}},Wq={class:"edit-embed"},qq={__name:"EditEmbed",emits:["close"],setup(t,{emit:e}){const{getters:o,dispatch:n,state:s}=nt(),{notify:a}=Le(),{t:l}=_t(),i=["WebAssembly"],r=e,u=C(null),p=c(()=>o.currentElementContent);Nt(()=>{u.value=p.value});const g=I=>i.some(E=>I.includes(E)),b=I=>!g(I),y=()=>{r("close")},k=()=>{if(s.user.user.isAccessManager){a({message:l("builder.embeddedCodeEditDisabled")}),y();return}if(!b(u.value)){y();return}n("mergeCurrentElementData",{elementData:{content:u.value}}),Et.logEvent({eventName:"website_builder.embed_code.edit"}),y()};return(I,E)=>(d(),v("div",Wq,[h(zo,{type:"editor","show-footer":"",title:I.$t("common.embedCode"),"save-btn-title":I.$t("common.embedCode"),"max-width":"560px","editor-popup-width":"560px",onClose:y,onSave:k},{default:_(()=>[h(Xt,{class:"edit-embed__input-label"},{default:_(()=>[j(w(I.$t("builder.editEmbed.addYourCodeHere")),1)]),_:1}),h(jq,{modelValue:u.value,"onUpdate:modelValue":E[0]||(E[0]=T=>u.value=T)},null,8,["modelValue"]),h(Yc,{class:"edit-embed__disclaimer",subtitle:I.$t("builder.editEmbed.disclaimer")},null,8,["subtitle"]),h(_o,{"feature-name":I.$t("builder.npsRateEmbed"),type:f(E0)},null,8,["feature-name","type"])]),_:1},8,["title","save-btn-title"])]))}},Yq=H(qq,[["__scopeId","data-v-3d70cc4f"]]),Kq=`
`,Zq=t=>`